Reconnect database after process forking

When connection is shared among forks, a known crash will occur on
MySQL.
Whitespace fix