There are differences in the ways code for traditional daemons and code for Windows services is written. Some of the rules for coding daemons can cause problems if you apply them to writing code for Windows services.
The following list describes things to avoid when writing code for Windows service applications:
The best way to access network drives is through the /net directory. This does not require a drive letter and you do not have to mount the network drive.
The following list describes things you should do when writing code for Windows service applications:
The Interix Software Development Kit (SDK) contains the same daemon() interface that is found on Berkeley Software Distribution (BSD) systems. The daemon() application programming interface (API) uses fork() and setsid() mentioned above.