From: Andre Noll Date: Fri, 11 Nov 2011 20:50:56 +0000 (+0100) Subject: Revert "server: Listen on command socket before daemonizing." X-Git-Tag: v0.4.9~8 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=b8ad8275c27afd58015dbc70ff9ce65637e96839;hp=b8ad8275c27afd58015dbc70ff9ce65637e96839 Revert "server: Listen on command socket before daemonizing." This reverts commit 7a4b6d5f19976ceac581f6dc235fcbd9b30c767f, which was a rather bad idea because it caused the afs process to inherit the open file descriptor of the command socket, so two processes listened on the command socket at the same time. Even worse, the afs process also inherited the command task in its scheduler setup, causing it to answer incoming connections as well. In fact it was more or less random which of the two processes served an incoming connection. If it was the afs process, interesting things happened in the command handler due to its address space being a copy of the afs process, where parts of what is needed for some commands not properly set up. For example the si and the sender commands segfaulted due to a NULL pointer dereference. It's weird that this bug was not noticed earlier. ---