Some more style fixes. Readded setsid on fork - got lost in previous refactorings.