diff options
author | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2011-06-21 17:31:08 +0000 |
---|---|---|
committer | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2011-06-21 17:31:08 +0000 |
commit | e7884bf87149523a28dac8c81b890d680655cbd8 (patch) | |
tree | 6fad4366ab0f38e88691278a55b07242076ede3d /usr.sbin/ftp-proxy | |
parent | b50edea001b4bd82ae333fbd20b35c63b80e60cc (diff) |
Convert SO_RTABLE's protocol level to the SOL_SOCKET; ok claudio
Diffstat (limited to 'usr.sbin/ftp-proxy')
-rw-r--r-- | usr.sbin/ftp-proxy/ftp-proxy.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/usr.sbin/ftp-proxy/ftp-proxy.c b/usr.sbin/ftp-proxy/ftp-proxy.c index 2a56df3406e..c077f8e61f9 100644 --- a/usr.sbin/ftp-proxy/ftp-proxy.c +++ b/usr.sbin/ftp-proxy/ftp-proxy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ftp-proxy.c,v 1.22 2011/04/28 00:17:28 mikeb Exp $ */ +/* $OpenBSD: ftp-proxy.c,v 1.23 2011/06/21 17:31:07 mikeb Exp $ */ /* * Copyright (c) 2004, 2005 Camiel Dobbelaar, <cd@sentia.nl> @@ -428,9 +428,8 @@ handle_connection(const int listen_fd, short event, void *ev) goto fail; } len = sizeof(s->client_rd); - if (client_sa->sa_family == AF_INET && - getsockopt(s->client_fd, IPPROTO_IP, SO_RTABLE, &s->client_rd, - &len)) { + if (getsockopt(s->client_fd, SOL_SOCKET, SO_RTABLE, &s->client_rd, + &len) && errno != ENOPROTOOPT) { logmsg(LOG_CRIT, "#%d getsockopt failed: %s", s->id, strerror(errno)); goto fail; |