On Tuesday 08 February 2011 09:01:19 Dirk Manske wrote: > Polling is always an ugly solution. If you really want to poll > /etc for changes every X seconds, then that X should be > configurable. > > But I would use (on Linux) inotify (in my program, not libcurl) > to watch resolv.conf etc. for changes and trigger the reload > function.
In the Fedora installer, we use res_init(3) to force glibc to re-read /etc/resolv.conf. It would be nice if libcurl provided a wrapper around it and then call the c-ares specific routine in case curl is built against c-ares. Kamil ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.html
