fixed some bugs in the dns and resolver manager