On Oct 24, 9:20am, t...@sarna.org (Ty Sarna) wrote: -- Subject: Re: CVS commit: src/lib/libc/resolv
| On Oct 24, 2009, at 9:08 AM, Ty Sarna wrote: | | > Unfortunately there's no way for me to use this feature currently. I | > think it would be sufficient if __res_check() were exposed and | > returned a flag indicating wether there was a changed or not. I will | > want to do some filtering of the search list in some cases, and it'd | > be better to build up my private modified copy of the search list | > only when the config changes rather than trying to figure it out on | > every query. | | Actually, better yet, return the time of last change instead of a | flag. In the case of a threaded program that uses both the getXXX API | and the low-level res_XXX api for some reason (perhaps MX lookups or | something else not supported at the getXXX level), I guess it's | possible that the nss module could end up res_get_state()'ing stale | res_states multiple times and re-initing when it doesn't need to. Again, the time is kept, so return that instead, or pass a pointer arg to res_check to populate it, if not null. christos