]> git.lizzy.rs Git - minetest.git/commit
ClientInterface: add a function to verify (correctly) if user limit was reached ...
authorLoïc Blot <nerzhul@users.noreply.github.com>
Wed, 16 Aug 2017 21:48:29 +0000 (23:48 +0200)
committerSmallJoker <mk939@ymail.com>
Sun, 3 Jun 2018 15:31:59 +0000 (17:31 +0200)
commit151c19a6be591d19d83cdd3c69583e7bf0828440
tree37470c00d6cb1472aff14cb86fe3bf53c13d7439
parent9d40d89d2721359b02c578366ebfd0ef1b91116d
ClientInterface: add a function to verify (correctly) if user limit was reached (#6258)

* ClientInterface: add a function to verify (correctly) if user limit was reached

CS_HelloSent is a better indicator of active slots than CS_Created, which are session objects created after init packet reception

Switch existing checks to ClientInterface::isUserLimitReached()

Use range-based for loop for getClientIds() used function too

This will fix #6254 (not the memory overhead if init is flooded)
src/clientiface.cpp
src/clientiface.h
src/network/serverpackethandler.cpp