]> granicus.if.org Git - cronie/commitdiff
anacron: make function declarations to be ansi compliant
authorSami Kerola <kerolasa@iki.fi>
Sat, 1 Dec 2012 23:44:29 +0000 (23:44 +0000)
committerTomas Mraz <tmraz@fedoraproject.org>
Fri, 21 Dec 2012 21:00:09 +0000 (22:00 +0100)
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
anacron/log.c
anacron/main.c
anacron/readtab.c
anacron/runjob.c

index 6f4be63ad4299843231ade22ef24cf7a888143dc..dbfe35481ab0f6f1435d515da6d7d3190ed044bb 100644 (file)
@@ -54,7 +54,7 @@ static int log_open = 0;
 int complaints = 0;
 
 static void
-xopenlog()
+xopenlog(void)
 {
     if (!log_open)
     {
@@ -64,7 +64,7 @@ xopenlog()
 }
 
 void
-xcloselog()
+xcloselog(void)
 {
     if (log_open) closelog();
     log_open = 0;
index 66928cce33368698d1c3d20be0d06a0192261120..7583bd0a53b7b9a53e0db496a34d488c4ffc157f 100644 (file)
@@ -65,7 +65,7 @@ int range_stop = -1;
 int preferred_hour = -1;
 
 static void
-print_version()
+print_version(void)
 {
     printf("Anacron \n"
           "Copyright (C) 1998  Itai Tzur <itzur@actcom.co.il>\n"
@@ -77,7 +77,7 @@ print_version()
 }
 
 static void
-print_usage()
+print_usage(void)
 {
     printf("Usage:\n");
     printf(" %s [options] [job] ...\n", program_name);
@@ -164,7 +164,7 @@ parse_opts(int argc, char *argv[])
 }
 
 pid_t
-xfork()
+xfork(void)
 /* Like fork(), only never returns on failure */
 {
     pid_t pid;
@@ -200,7 +200,7 @@ xclose(int fd)
 }
 
 static void
-go_background()
+go_background(void)
 /* Become a daemon. The foreground process exits successfully. */
 {
     pid_t pid;
@@ -247,7 +247,7 @@ handle_sigusr1(int unused ATTRIBUTE_UNUSED)
 }
 
 static void
-set_signal_handling()
+set_signal_handling(void)
 /* We only use SIGALRM, SIGCHLD and SIGUSR1, and we unblock them only
  * in wait_signal().
  */
@@ -284,7 +284,7 @@ set_signal_handling()
 }
 
 static void
-wait_signal()
+wait_signal(void)
 /* Return after a signal is caught */
 {
     sigset_t ss;
@@ -297,7 +297,7 @@ wait_signal()
 }
 
 static void
-wait_children()
+wait_children(void)
 /* Wait until we have no more children (of any kind) */
 {
     while (running_jobs > 0 || running_mailers > 0)
@@ -311,7 +311,7 @@ wait_children()
 }
 
 static void
-orderly_termination()
+orderly_termination(void)
 /* Execution is diverted here, when we get SIGUSR1 */
 {
     explain("Received SIGUSR1");
@@ -341,7 +341,7 @@ xsleep(unsigned int n)
 }
 
 static void
-wait_jobs()
+wait_jobs(void)
 /* Wait until there are no running jobs,
  * servicing SIGCHLDs and SIGUSR1s in the meantime.
  */
@@ -356,7 +356,7 @@ wait_jobs()
 }
 
 static void
-record_start_time()
+record_start_time(void)
 {
     struct tm *tm_now;
 
@@ -394,7 +394,7 @@ time_till(job_rec *jr)
 }
 
 static void
-fake_jobs()
+fake_jobs(void)
 {
     int j;
 
@@ -409,7 +409,7 @@ fake_jobs()
 }
 
 static void
-explain_intentions()
+explain_intentions(void)
 {
     int j;
 
index 96a8f99e10e46fad32466ae2cee53b3a93590393..34bd5c0d987d85def716d1d14864c7968efde949 100644 (file)
@@ -81,7 +81,7 @@ conv2int(const char *s)
 }
 
 static char *
-read_tab_line ()
+read_tab_line (void)
 /* Read one line and return a pointer to it.
 Return NULL if no more lines.
  */
@@ -380,7 +380,7 @@ execution_order(const job_rec **job1, const job_rec **job2)
 }
 
 void
-arrange_jobs()
+arrange_jobs(void)
 /* Make an array of pointers to jobs that are going to be executed,
  * and arrange them in the order of execution.
  * Also lock these jobs.
index 9656254ea9753fd46515ca3d5ea3f2b0b887997e..ab499b812f863ba305e6853211f7e61b6c07c3c2 100644 (file)
@@ -85,7 +85,7 @@ file_size(int fd)
 }
 
 static char *
-username()
+username(void)
 {
     struct passwd *ps;
 
@@ -325,7 +325,7 @@ tend_job(job_rec *jr, int status)
 }
 
 void
-tend_children()
+tend_children(void)
 /* This is called whenever we get a SIGCHLD.
  * Takes care of zombie children.
  */