compile on systems without TCP_MD5SIG (e.g. OSX)

This commit is contained in:
Damien Miller 2015-01-27 23:07:43 +11:00
parent 358964f308
commit 69ff64f696
1 changed files with 2 additions and 0 deletions

View File

@ -1144,11 +1144,13 @@ set_common_sockopts(int s)
{
int x = 1;
#ifdef TCP_MD5SIG
if (Sflag) {
if (setsockopt(s, IPPROTO_TCP, TCP_MD5SIG,
&x, sizeof(x)) == -1)
err(1, NULL);
}
#endif
if (Dflag) {
if (setsockopt(s, SOL_SOCKET, SO_DEBUG,
&x, sizeof(x)) == -1)