Yield cf-serverd lock at the end of its execution.
Close listening socket before exiting.
Give GenerateDiffReports access to the agent config.
Merge pull request #1689 from kacfengine/bootstrap_check

Give GenerateDiffReports access to the agent config.
Failing to set SO_LINGER is not a catastrophic event, do not exit.
Do not log at level ERR non-catastrophic events.
The caller exits, no need to do it in the callee.
No change in logic, just moved things around to make more functions static.
Merge pull request #1686 from jimis/yield_serverd_resources

Yield serverd resources
Fix build: Remove redundant function declaration.