Sourceware Bugzilla – Attachment 4402 Details for
Bug 10851
no fallback to nameserver 0.0.0.0 if /etc/resolv.conf is missing
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
alternative patch
glibc-nameserver-localhost.diff (text/plain), 860 bytes, created by
Petr Baudis
on 2009-11-20 08:28:19 UTC
(
hide
)
Description:
alternative patch
Filename:
MIME Type:
Creator:
Petr Baudis
Created:
2009-11-20 08:28:19 UTC
Size:
860 bytes
patch
obsolete
>2009-11-20 Petr Baudis <pasky@suse.cz> > > [BZ #10851] > * resolv/res_init.c (__res_vinit): Initialize nscount again to > one so that the default localhost nameserver record is used. > >diff --git a/resolv/res_init.c b/resolv/res_init.c >index 40dbe7d..99ef8cf 100644 >--- a/resolv/res_init.c >+++ b/resolv/res_init.c >@@ -183,7 +183,7 @@ __res_vinit(res_state statp, int preinit) { > #endif > statp->nsaddr.sin_family = AF_INET; > statp->nsaddr.sin_port = htons(NAMESERVER_PORT); >- statp->nscount = 0; >+ statp->nscount = 1; > statp->ndots = 1; > statp->pfcode = 0; > statp->_vcsock = -1; >@@ -420,7 +420,8 @@ __res_vinit(res_state statp, int preinit) { > continue; > } > } >- statp->nscount = nservall; >+ if (nservall > 0) >+ statp->nscount = nservall; > #ifdef _LIBC > if (nservall - nserv > 0) { > statp->_u._ext.nscount6 = nservall - nserv;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 10851
:
4322
|
4369
| 4402