c294a46fc75274b385332a9d70fe7e598503dfd8
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / uclibc / 0.9.33.2 / 0046-inet-fix-getting-the-nameserver-from-_res-state-afte.patch
1 From 41063cebafa7b90427837757db00cdbfe2690f82 Mon Sep 17 00:00:00 2001
2 From: Felix Fietkau <nbd@openwrt.org>
3 Date: Fri, 21 Sep 2012 17:29:12 +0200
4 Subject: [PATCH] inet: fix getting the nameserver from _res state after
5  res_init.
6
7 Fixes displaying the nameserver in busybox nslookup.
8
9 Signed-off-by: Felix Fietkau <nbd@openwrt.org>
10 Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
11 ---
12  libc/inet/resolv.c |    2 +-
13  1 file changed, 1 insertion(+), 1 deletion(-)
14
15 diff --git a/libc/inet/resolv.c b/libc/inet/resolv.c
16 index 7bd634c..6f58260 100644
17 --- a/libc/inet/resolv.c
18 +++ b/libc/inet/resolv.c
19 @@ -3653,11 +3653,11 @@ res_init(void)
20          */
21         if (!_res.id)
22                 _res.id = res_randomid();
23 -       __res_sync = res_sync_func;
24  
25         __UCLIBC_MUTEX_UNLOCK(__resolv_lock);
26  
27         __res_vinit(&_res, 1);
28 +       __res_sync = res_sync_func;
29  
30         return 0;
31  }
32 -- 
33 1.7.10.4
34