diff options
Diffstat (limited to 'utils')
-rw-r--r-- | utils/nfsynproxy.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/utils/nfsynproxy.c b/utils/nfsynproxy.c index 9b6de93b..baedc92c 100644 --- a/utils/nfsynproxy.c +++ b/utils/nfsynproxy.c @@ -109,20 +109,20 @@ static void probe_host(const char *host) goto err2; } - if (pcap_compile(ph, &fp, "src host 127.0.0.1 and tcp and src port 80", - 1, PCAP_NETMASK_UNKNOWN) == -1) { - pcap_perror(ph, "pcap_compile"); - goto err2; - } - if (pcap_setfilter(ph, &fp) == -1) { pcap_perror(ph, "pcap_setfilter"); - goto err3; + goto err2; } if (pcap_activate(ph) != 0) { pcap_perror(ph, "pcap_activate"); - goto err3; + goto err2; + } + + if (pcap_compile(ph, &fp, "src host 127.0.0.1 and tcp and src port 80", + 1, PCAP_NETMASK_UNKNOWN) == -1) { + pcap_perror(ph, "pcap_compile"); + goto err2; } fd = socket(AF_INET, SOCK_STREAM, 0); |