Merge changes I82856f84,I97c44ff8 into qt-dev

* changes:
  Simplify socket configuration in DNSResponder::startServer()
  resolv: speed up the termination of loop thread in testing DNS and TLS servers