add: ONVERBOSE(syslog(LOG_INFO, "Daemonizing"));
context: int daemonize(){  /*   * Tenta desconectar terminal de controle.   */  const char *tty_path = "/dev/tty";  int tty = open(tty_path, O_NOCTTY);  if (tty == -1)    syslog(LOG_WARNING, "daemonize(): can't open tty: %s: %m", tty_path);  else {    if (ioctl(tty, TIOCNOTTY))      syslog(LOG_WARNING, "daemonize(): can't detach terminal: %m");    if (close(tty))      syslog(LOG_WARNING, "daemonize(): can't close tty: %s: %m", tty_path);  }  /*   * Garante que futuros open()s nao vao alocar um terminal de controle.   */  pid_t pid = fork();  if (pid) {    if (pid < 0) {      syslog(LOG_ERR, "daemonize(): fork() failed");      return -1;    }    /*      * Parent exits     */    exit(0);  }  /*   * Child proceeds   */  return 0;}