Adapt rpcbind(8) to new return value from socket(2) for unsupported
address families.
This commit is contained in:
parent
b7414305ba
commit
d59a581d86
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: rpcbind.c,v 1.8 2006/05/25 02:35:32 christos Exp $ */
|
||||
/* $NetBSD: rpcbind.c,v 1.9 2006/06/14 16:25:17 ginsbach Exp $ */
|
||||
|
||||
/*
|
||||
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
|
||||
@ -249,8 +249,11 @@ init_transport(struct netconfig *nconf)
|
||||
* XXX - using RPC library internal functions.
|
||||
*/
|
||||
if ((fd = __rpc_nconf2fd(nconf)) < 0) {
|
||||
int non_fatal = errno == EPROTONOSUPPORT;
|
||||
syslog(non_fatal?LOG_DEBUG:LOG_ERR, "cannot create socket for %s", nconf->nc_netid);
|
||||
int non_fatal;
|
||||
|
||||
non_fatal = (errno == EAFNOSUPPORT || errno == EPROTONOSUPPORT);
|
||||
syslog(non_fatal?LOG_DEBUG:LOG_ERR,
|
||||
"cannot create socket for %s", nconf->nc_netid);
|
||||
return (1);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user