diff options
Diffstat (limited to 'nametoaddr.c')
-rw-r--r-- | nametoaddr.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/nametoaddr.c b/nametoaddr.c index 45743c71..eea629a9 100644 --- a/nametoaddr.c +++ b/nametoaddr.c @@ -702,11 +702,12 @@ pcap_ether_aton(const char *s) return (e); } +#ifndef HAVE_ETHER_HOSTTON /* - * XXX - not thread-safe! + * Roll our own. + * XXX - not thread-safe, because pcap_next_etherent() isn't thread- + * safe! Needs a mutex or a thread-safe pcap_next_etherent(). */ -#ifndef HAVE_ETHER_HOSTTON -/* Roll our own */ u_char * pcap_ether_hostton(const char *name) { @@ -737,7 +738,10 @@ pcap_ether_hostton(const char *name) return (NULL); } #else -/* Use the os supplied routines */ +/* + * Use the OS-supplied routine. + * This *should* be thread-safe; the API doesn't have a static buffer. + */ u_char * pcap_ether_hostton(const char *name) { |