[git commit] inet: fix getting the nameserver from _res state after res_init.

Bernhard Reutner-Fischer rep.dot.nop at gmail.com
Fri Mar 29 09:30:21 UTC 2013


commit: http://git.uclibc.org/uClibc/commit/?id=60e5c34fe39232b5f92bad60d986fda29e4ba05f
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/master

Fixes displaying the nameserver in busybox nslookup.

Signed-off-by: Felix Fietkau <nbd at openwrt.org>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop at gmail.com>
---
 libc/inet/resolv.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libc/inet/resolv.c b/libc/inet/resolv.c
index 4777977..ffd3fe8 100644
--- a/libc/inet/resolv.c
+++ b/libc/inet/resolv.c
@@ -3645,11 +3645,11 @@ res_init(void)
 	 */
 	if (!_res.id)
 		_res.id = res_randomid();
-	__res_sync = res_sync_func;
 
 	__UCLIBC_MUTEX_UNLOCK(__resolv_lock);
 
 	__res_vinit(&_res, 1);
+	__res_sync = res_sync_func;
 
 	return 0;
 }


More information about the uClibc-cvs mailing list