소스 검색

Fehler bei unverschlüsselten Clients behoben

Kolja Strohm 6 년 전
부모
커밋
8ae2ee71b2
1개의 변경된 파일4개의 추가작업 그리고 4개의 파일을 삭제
  1. 4 4
      ShopServer/ShopServer.cpp

+ 4 - 4
ShopServer/ShopServer.cpp

@@ -61,7 +61,7 @@ ShopServer::~ShopServer()
 // nicht constant 
 void ShopServer::runn()
 {
-    while( !end )
+    while( !end && aServer->isConnected() )
     {
         SSLSKlient *klient;
         klient = aServer->getKlient();
@@ -73,7 +73,7 @@ void ShopServer::runn()
             return;
         }
         if( !klient )
-            return;
+            continue;
         ShSAKlient *clHandle = new ShSAKlient( klient, getThis() );
         clHandle->start();
     }
@@ -81,12 +81,12 @@ void ShopServer::runn()
 
 void ShopServer::thread()
 {
-    while( 1 )
+    while( server->isConnected() )
     {
         SKlient *klient;
         klient = server->getKlient();
         if( !klient )
-            break;
+            continue;
 		Framework::getThreadRegister()->cleanUpClosedThreads();
         ShSKlient *clHandle = new ShSKlient( klient, getThis() );
         EnterCriticalSection( &cs );