wait for deamon pid after SIGTERM to prevent it from becoming zombie
Merge pull request #297 from prymitive/dfix

fixed dump daemon process termination