diff options
author | Kelly Washington <kelly@lindenlab.com> | 2007-06-21 22:40:22 +0000 |
---|---|---|
committer | Kelly Washington <kelly@lindenlab.com> | 2007-06-21 22:40:22 +0000 |
commit | e03bb0606a10f29c8b94909a713a5bb5c69e88b7 (patch) | |
tree | 6d8d07894579438c8cc70e08f5730c3c95dfe768 /indra/llmessage/net.cpp | |
parent | 2638f12f95eea692502836cf6548b4a0b234d009 (diff) |
merge -r62831:64079 branches/maintenance to release
Diffstat (limited to 'indra/llmessage/net.cpp')
-rw-r--r-- | indra/llmessage/net.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/indra/llmessage/net.cpp b/indra/llmessage/net.cpp index 9e83ce1434..8cd7180f9a 100644 --- a/indra/llmessage/net.cpp +++ b/indra/llmessage/net.cpp @@ -269,8 +269,12 @@ S32 start_net(S32& socket_out, int& nPort) return 0; } -void end_net() +void end_net(S32& socket_out) { + if (socket_out < 0) + { + closesocket(socket_out); + } WSACleanup(); } @@ -437,8 +441,12 @@ S32 start_net(S32& socket_out, int& nPort) return 0; } -void end_net() +void end_net(S32& socket_out) { + if (socket_out < 0) + { + close(socket_out); + } } int receive_packet(int hSocket, char * receiveBuffer) |