If we get EBUSY when binding to a SAP, clear out the error string we get
from it, so that our caller doesn't treat it as a warning.
This commit is contained in:
parent
0dfd667893
commit
1d1d486342
|
@ -70,7 +70,7 @@
|
||||||
|
|
||||||
#ifndef lint
|
#ifndef lint
|
||||||
static const char rcsid[] _U_ =
|
static const char rcsid[] _U_ =
|
||||||
"@(#) $Header: /tcpdump/master/libpcap/pcap-dlpi.c,v 1.108.2.3 2005-04-17 17:20:59 guy Exp $ (LBL)";
|
"@(#) $Header: /tcpdump/master/libpcap/pcap-dlpi.c,v 1.108.2.4 2005-04-17 17:26:14 guy Exp $ (LBL)";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
|
@ -1043,8 +1043,11 @@ dl_dohpuxbind(int fd, char *ebuf)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* For EBUSY, try the next SAP value; that means that
|
* For EBUSY, try the next SAP value; that means that
|
||||||
* somebody else is using that SAP.
|
* somebody else is using that SAP. Clear ebuf so
|
||||||
|
* that application doesn't report the "Device busy"
|
||||||
|
* error as a warning.
|
||||||
*/
|
*/
|
||||||
|
*ebuf = '\0';
|
||||||
hpsap++;
|
hpsap++;
|
||||||
if (hpsap > 100)
|
if (hpsap > 100)
|
||||||
return (-1);
|
return (-1);
|
||||||
|
|
Reference in New Issue