printf("tty= %s\n", inittab[i].tty);
printf("termcap= %s\n", inittab[i].termcap);
}
- exit(0);
+ exit(EXIT_SUCCESS);
#endif
signal (SIGHUP, sighup_handler); /* Better semantics with signal(2) */
case 0: /* Child */
execl (final_prog, final_prog, "start", NULL);
err ( _("error running finalprog\n") );
- _exit (1);
+ _exit (EXIT_FAILURE);
break;
case -1: /* Error */
err ( _("error forking finalprog\n") );
execve(inittab[i].toks[0], inittab[i].toks, env);
err(_("exec failed\n"));
sleep(5);
- _exit(1);
+ _exit(EXIT_FAILURE);
}
}
caught_sigint = 1;
kill (rc_child, SIGKILL);
- if (no_reboot) _exit (1) /*kill (0, SIGKILL)*/;
+ if (no_reboot) _exit (EXIT_FAILURE) /*kill (0, SIGKILL)*/;
sync ();
sync ();
pid = fork ();
{
FILE *fp;
- if ( ( fp = fopen (command->name, "w") ) == NULL ) _exit (1);
+ if ( ( fp = fopen (command->name, "w") ) == NULL ) _exit (EXIT_FAILURE);
show_scripts (fp, available_list.first, "AVAILABLE");
show_scripts (fp, starting_list.first, "STARTING");
fputs ("UNAVAILABLE SERVICES:\n", fp);
fprintf (fp, "%s (%s)\n", service->name,
service->failed ? "FAILED" : "not configured");
fclose (fp);
- _exit (0);
+ _exit (EXIT_SUCCESS);
}
break;
case COMMAND_PROVIDE: