diff options
Diffstat (limited to 'contrib/bind/lib/irs/nis_nw.c')
-rw-r--r-- | contrib/bind/lib/irs/nis_nw.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/contrib/bind/lib/irs/nis_nw.c b/contrib/bind/lib/irs/nis_nw.c index 72ec391..bc659f3 100644 --- a/contrib/bind/lib/irs/nis_nw.c +++ b/contrib/bind/lib/irs/nis_nw.c @@ -16,7 +16,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static const char rcsid[] = "$Id: nis_nw.c,v 1.15 1999/01/18 07:46:58 vixie Exp $"; +static const char rcsid[] = "$Id: nis_nw.c,v 1.16 2001/05/29 05:49:15 marka Exp $"; #endif /* LIBC_SCCS and not lint */ /* Imports */ @@ -187,6 +187,7 @@ static struct nwent * nw_byname(struct irs_nw *this, const char *name, int af) { struct pvt *pvt = (struct pvt *)this->private; int r; + char *tmp; if (init(this) == -1) return (NULL); @@ -197,8 +198,9 @@ nw_byname(struct irs_nw *this, const char *name, int af) { return (NULL); } nisfree(pvt, do_val); - r = yp_match(pvt->nis_domain, networks_byname, (char *)name, - strlen(name), &pvt->curval_data, &pvt->curval_len); + DE_CONST(name, tmp); + r = yp_match(pvt->nis_domain, networks_byname, tmp, + strlen(tmp), &pvt->curval_data, &pvt->curval_len); if (r != 0) { RES_SET_H_ERRNO(pvt->res, HOST_NOT_FOUND); return (NULL); |