diff options
author | Patrick McHardy <kaber@trash.net> | 2007-06-26 15:29:45 +0000 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2007-06-26 15:29:45 +0000 |
commit | 76258727e101a0960cc8fcf84d9a451e4b5fd9b5 (patch) | |
tree | 367629a7babbf74cca351e2473118638c0562bb2 /ip6tables.c | |
parent | 06e88ddd97aaacf50a8ca2418e9c6c5d95b99865 (diff) |
Fix "iptables getsockopt failed strangely" when querying revisions for non-existant matches and targets
Reported by Joseph Jezak <josejx@gentoo.org>.
Diffstat (limited to 'ip6tables.c')
-rw-r--r-- | ip6tables.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ip6tables.c b/ip6tables.c index f316c7a9..6b2766b7 100644 --- a/ip6tables.c +++ b/ip6tables.c @@ -1130,7 +1130,7 @@ static int compatible_revision(const char *name, u_int8_t revision, int opt) max_rev = getsockopt(sockfd, IPPROTO_IPV6, opt, &rev, &s); if (max_rev < 0) { /* Definitely don't support this? */ - if (errno == EPROTONOSUPPORT) { + if (errno == ENOENT || errno == EPROTONOSUPPORT) { close(sockfd); return 0; } else if (errno == ENOPROTOOPT) { |