William Lachance (wlach) wrote,
William Lachance

Why oh why...

Why oh why do most daemons fork into the background by default? For example:

  gnome-screensaver [OPTION...]

Help Options:
  -?, --help               Show help options
  --help-all               Show all help options
  --help-gtk               Show GTK+ Options

Application Options:
  --version                Version of this application
  --no-daemon              Don't become a daemon
  --debug                  Enable debugging code
  --display=DISPLAY        X display to use

If I'm going to run a daemon manually, chances are that I'm trying to debug it. When you're debugging things, you want to be able to kill it quickly if need be (not to mention easily see what it's spewing out...). I certainly don't want it to fork into the background, daemonize itself, and start writing to the syslog (in the case of system-level daemons).

How much work is it for the writer of an initscript (or session manager, what have you) to add an argument to the program's arglist? Practically zero. Meanwhile I (the helpful person debugging your daemon) is doomed to waste valuable time figuring out how to get the behaviour that I need. This makes no sense!
Tags: advogato
  • Post a new comment


    Comments allowed for friends only

    Anonymous comments are disabled in this journal

    default userpic

    Your IP address will be recorded