Fix issue #7

When shutting down rpc server, we need to wait till all current
alive connections are closed. Otherwise some alive connection
might access the server's data (PollMgr), it will cause SIGSEGV.