You know, I never really questioned the syntax, but from my limited experience, it is a way actually executing the fork. The if($pid) part is true, if the system can fork and return a non-zero pid. So the fork occurs and the parent gets a pid, and the child receives a 0. It is the c way of forking. So both sections of code get executed, but one is in the parent and the other is the child.