My guess is that on Linux, the call to gethostbyname is cached somewhere outside the resolver and the updated information does not reach your program. I don't know enough about Linux to know how to make the C library, or the resolver deliver you the updated information immediately.
In reply to Re: /etc/hosts is not evaluated after modification on Linux
by Corion
in thread /etc/hosts is not evaluated after modification on Linux
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |