Initialise _res.nsaddr_list in res_init(), fixing some programs which depend
authorsthen <sthen@openbsd.org>
Wed, 15 Jan 2014 02:25:34 +0000 (02:25 +0000)
committersthen <sthen@openbsd.org>
Wed, 15 Jan 2014 02:25:34 +0000 (02:25 +0000)
commit38a63ed178c3f19f41ef0c3434b850a5cf50fd7e
tree23f0f908240b309a72b17982be35acacbf2cf313
parent55819bcb52f0a159ceb8b5083a9b8497698a2eb9
Initialise _res.nsaddr_list in res_init(), fixing some programs which depend
on bind resolver internals. Note, the list will not be updated if resolv.conf
is changed while the program runs unless the caller resets the RES_INIT flag.
Approach suggested by otto@, original diff from Kapetanakis Giannis, fix
suggested by tedu@ and dug up again by Riccardo Mottola.  Looks ok to eric@.
lib/libc/asr/res_init.c