libt2n: (gerd) small fixes, hello unit tests
[libt2n] / src / command_client.cpp
index c0e863c..41c74de 100644 (file)
@@ -52,7 +52,7 @@ void command_client::read_hello()
 {
     // TODO: fix timeout
     string resultpacket;
-    while(!c.get_packet(resultpacket))
+    while(!c.get_packet(resultpacket) && !c.is_closed())
         c.fill_buffer();
 
     istringstream hello(resultpacket);