Add NotifyStartedFunc field to Server

Adds a field, NotifyStartedFunc func() to Server.

If non-nil, it is called after a server starts listening. This is useful
for synchronization purposes, for example when a daemon needs to drop
privileges after binding. Otherwise, there is no way to determine when
the server has begun listening and hardcoded delays (!) must be used or
race conditions may occur.
I would kill this function and just do the if-then inline for each of the 2 calls. Otherwise LGTM