Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix error checking
  • Loading branch information
Eric Eilebrecht committed Sep 26, 2016
commit 8e85830cadb97f7324f7344457cfb39125ec53bc
2 changes: 1 addition & 1 deletion src/Native/Unix/System.Native/pal_networking.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2177,7 +2177,7 @@ SystemNative_SetSockOpt(intptr_t socket, int32_t socketOptionLevel, int32_t sock
// SO_REUSEADDR + SO_REUSEPORT other systems.
//
int err = setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, optionValue, static_cast<socklen_t>(optionLen));
if (err != 0)
if (err == 0)
{
err = setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, optionValue, static_cast<socklen_t>(optionLen));
}
Expand Down