X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=cl_main.c;h=b0c913d054fa1e0092262e219ba89f46c56b8664;hp=7af224e045bb68c1aa496b123f3eaeefde0771a7;hb=f9d7e79153535d266416bdc2cfb286aa276f6f18;hpb=621bfbef71c6a151a6191ddbc0fabd0629e830ac diff --git a/cl_main.c b/cl_main.c index 7af224e0..b0c913d0 100644 --- a/cl_main.c +++ b/cl_main.c @@ -427,15 +427,13 @@ void CL_EstablishConnection(const char *host, int firstarg) #ifdef CONFIG_MENU M_Update_Return_Reason(""); #endif - cls.demonum = -1; - - // stop demo loop in case this fails - if (cls.demoplayback) - CL_StopPlayback(); // if downloads are running, cancel their finishing action Curl_Clear_forthismap(); + // Disconnect from the current server, or stop a running demo. + CL_Disconnect(); + // make sure the client ports are open before attempting to connect NetConn_UpdateSockets();