day 2: fix bugs

TODO:
*) don't check when dns response is cached
*) don't do dns lookup if a server is defined with an IP address
*) TODOs in source files

Signed-off-by: paulyang <y_y@neusoft.com>