diff options
author | Guy Harris <guy@alum.mit.edu> | 2015-02-03 13:45:33 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2015-02-05 17:42:36 -0800 |
commit | 0f3e3eca129a148a7853110c0ccc528ea2a91567 (patch) | |
tree | cc32644abb0496456e6982ba8dd272c45e63e4fe /pcap-linux.c | |
parent | 3159b2e50b768f684194e318f0bcc392ec94e800 (diff) |
Some cleanups.
Diffstat (limited to 'pcap-linux.c')
-rw-r--r-- | pcap-linux.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/pcap-linux.c b/pcap-linux.c index 8c1caaf9..99d76218 100644 --- a/pcap-linux.c +++ b/pcap-linux.c @@ -5525,10 +5525,14 @@ iface_ethtool_get_ts_info(pcap_t *handle, char *ebuf) int num_ts_types; int i, j; - /* ioctl() will fail for the "any" pseudo-device with ENODEV. */ - if (! strcmp(handle->opt.source, "any")) { - iface_set_default_ts_types(handle); - return 0; + /* + * This doesn't apply to the "any" device; you have to ask + * specific devices for their capabilities, so just default + * to saying we support all of them. + */ + if (strcmp(handle->opt.source, "any") == 0) { + iface_set_default_ts_types(handle); + return 0; } /* |