await client listen

This commit is contained in:
waltem01 2022-07-01 07:07:54 +02:00
parent 50333f26d6
commit a054b0137c

View File

@ -75,7 +75,7 @@ public static class Connection {
// Accept any client, stop listening after first client is connected and return client
own.BeginAccept(new AsyncCallback(AcceptCallback), own);
// Wait for and close connection
while (!own.Connected)
while (self == null)
Thread.Sleep(250);
own.Close();
}