summaryrefslogtreecommitdiffstats
path: root/src/OSSupport/ServerHandleImpl.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2020-07-18Move IsValidSocket out of global namespaceTiger Wang1-7/+10
2020-05-15Enable some more clang-tidy linter checks (#4738)peterbell101-5/+5
* Avoid inefficient AString -> c_str() -> AString round trip * Avoid redundant string init expressions * Avoid unnecessary return, continue, etc. * Add .clang-format to help with clang-tidy fix-its * Avoid unnecessary passing by value * Avoid unnecessary local copying * Avoid copying in range-for loops * Avoid over-complicated boolean expressions * Some violations missed by my local clang-tidy * Allow unnecessary continue statements * Add brackets * Another expression missed locally * Move BindingsProcessor call into clang-tidy.sh and add space * Fix pushd not found error * Different grouping of CheckBlockInteractionRate
2020-04-15ServerHandle: Fix closing failed servers. (#4653)Mattes D1-1/+4
If the cServerHandle failed to listen, closing it would then crash Cuberite.
2020-04-02Use a reasonable listen backlog value (#4597)Mat1-2/+2
2018-05-02Prefer static_cast to reinterpret_cast (#4223)peterbell101-1/+1
* Change reinterpret_cast -> static_cast wherever possible * Remove more unnecessary `const_cast`s. reinterpret_casts should be avoided for the same reason as c-style casts - they don't do any type-checking. reinterpret_cast was mainly being used for down-casting in inheritance hierarchies but static_cast works just as well while also making sure that there is actually an inheritance relationship there.
2015-08-18Some warning fixesJulian Laubstein1-1/+3
2015-07-07Network: Fixed ServerHandle's address formatting.Mattes D1-2/+2
2015-02-18Network: Fixed two-socket servers.Mattes D1-1/+1
2015-02-08ServerHandle: Fixed socket reuse.Mattes D1-10/+30
Fixes CID 104670, CID 104670 and CID 103724.
2015-02-07Use evutil_make_listen_socket_reuseableHowaner1-16/+6
2015-02-07Set reuse flag to socketsHowaner1-1/+24
Should fix #1726
2015-01-27Fixed listening ports not closed on cServerHandle::Close.Mattes D1-0/+3
2015-01-27ServerHandleImpl: Removed needless diagnostic output.Mattes D1-4/+0
2015-01-27cNetwork: Fixed IP address reading for incoming connections.Mattes D1-1/+2
2015-01-23cNetwork: Added self pointers to keep objects alive for callbacks.Mattes D1-2/+8
Ref.: http://forum.mc-server.org/showthread.php?tid=1700&pid=17947#pid17947
2015-01-22cNetwork: Added link creation callback.Mattes D1-0/+2
This allows the callback classes to store the link inside them and use it internally later on, mainly for sending data.
2015-01-22cNetwork: Changed listening API.Mattes D1-13/+36
The link-callbacks for each new accepted link are now received from the OnIncomingConnection listen-callback.
2015-01-22cNetwork: Added error message to error callbacks.Mattes D1-5/+6
2015-01-22cTCPLinkImpl: Fixed type conversion warning.Mattes D1-1/+1
2015-01-22cNetwork: Split the main cpp file into several files.Mattes D1-0/+302