mirror of https://github.com/OpenRCT2/OpenRCT2.git
Fix #5984: Allow socket binding to same port after crash
This commit is contained in:
parent
fabf7f9fb5
commit
424f2fcef5
|
@ -13,6 +13,7 @@
|
|||
- Fix: [#5920] Placing guest spawn doesn't do anything every 3rd click
|
||||
- Fix: [#5939] Crash when importing 'Six Flags Santa Fe'.
|
||||
- Fix: [#5977] Custom music files not showing up in music list
|
||||
- Fix: [#5984] Allow socket binding to same port after crash
|
||||
- Improved: [#4301] Leading and trailing whitespace in player name is now removed.
|
||||
- Improved: [#5859] OpenGL rendering performance
|
||||
- Improved: [#5863] Switching drawing engines no longer requires the application to restart.
|
||||
|
|
|
@ -147,6 +147,12 @@ public:
|
|||
log_error("IPV6_V6ONLY failed. %d", LAST_SOCKET_ERROR());
|
||||
}
|
||||
|
||||
value = 1;
|
||||
if (setsockopt(_socket, SOL_SOCKET, SO_REUSEADDR, (const char*)&value, sizeof(value)) != 0)
|
||||
{
|
||||
log_error("SO_REUSEADDR failed. %d", LAST_SOCKET_ERROR());
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
// Bind to address:port and listen
|
||||
|
|
Loading…
Reference in New Issue