From: Perttu Ahola Date: Thu, 8 Aug 2013 03:10:45 +0000 (+0300) Subject: Don't freak out when a client sends multiple TOSERVER_INIT packets; also log one... X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=35c5ccfad34417e37ecb76bfb2995e47142b272e;p=zefram%2Fminetest%2Fminetest_engine.git Don't freak out when a client sends multiple TOSERVER_INIT packets; also log one thing more. --- diff --git a/src/server.cpp b/src/server.cpp index 1fea8afe..7926b879 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -1810,7 +1810,15 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) if(datasize < 2+1+PLAYERNAME_SIZE) return; - verbosestream<<"Server: Got TOSERVER_INIT from "<net_proto_version != 0){ + verbosestream<<"Server: Ignoring multiple TOSERVER_INITs from " + < 2 * g_settings->getU16("max_users")){ + verbosestream<<"Server: DenyAccess: Too many clients; getting rid of " + <<"peer_id="<