From 1ceba9360b4de2f9ad3f20c23133bbfec027c036 Mon Sep 17 00:00:00 2001 From: "greg@kroah.com" Date: Mon, 18 Oct 2004 23:14:20 -0700 Subject: [PATCH] sparse cleanups on the tree --- namedev_parse.c | 4 ++-- udev.c | 1 + udev_remove.c | 1 + udevd.c | 12 ++++++------ 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/namedev_parse.c b/namedev_parse.c index 7e37833202..22e3523f3d 100644 --- a/namedev_parse.c +++ b/namedev_parse.c @@ -441,7 +441,7 @@ exit: return retval; } -int namedev_init_rules() +int namedev_init_rules(void) { struct stat stats; @@ -453,7 +453,7 @@ int namedev_init_rules() udev_rules_filename, RULEFILE_SUFFIX); } -int namedev_init_permissions() +int namedev_init_permissions(void) { struct stat stats; diff --git a/udev.c b/udev.c index dfb2baddbc..839bfa6520 100644 --- a/udev.c +++ b/udev.c @@ -28,6 +28,7 @@ #include #include #include +#include #include "libsysfs/sysfs/libsysfs.h" #include "udev.h" diff --git a/udev_remove.c b/udev_remove.c index 0dcec731ea..cd9d27f8dc 100644 --- a/udev_remove.c +++ b/udev_remove.c @@ -28,6 +28,7 @@ #include #include #include +#include #include "udev.h" #include "udev_lib.h" diff --git a/udevd.c b/udevd.c index 421c25a6e8..9e0f71b583 100644 --- a/udevd.c +++ b/udevd.c @@ -177,7 +177,7 @@ static struct hotplug_msg *running_with_devpath(struct hotplug_msg *msg) } /* exec queue management routine executes the events and delays events for the same devpath */ -static void exec_queue_manager() +static void exec_queue_manager(void) { struct hotplug_msg *loop_msg; struct hotplug_msg *tmp_msg; @@ -207,7 +207,7 @@ static void msg_move_exec(struct hotplug_msg *msg) } /* msg queue management routine handles the timeouts and dispatches the events */ -static void msg_queue_manager() +static void msg_queue_manager(void) { struct hotplug_msg *loop_msg; struct hotplug_msg *tmp_msg; @@ -241,7 +241,7 @@ recheck: if (list_empty(&msg_list) == 0) { struct itimerval itv = {{0, 0}, {EVENT_TIMEOUT_SEC - msg_age, 0}}; dbg("next event expires in %li seconds", EVENT_TIMEOUT_SEC - msg_age); - setitimer(ITIMER_REAL, &itv, 0); + setitimer(ITIMER_REAL, &itv, NULL); } } @@ -366,11 +366,11 @@ static void udev_done(int pid) } } -static void reap_kids() +static void reap_kids(void) { /* reap all dead children */ while(1) { - int pid = waitpid(-1, 0, WNOHANG); + int pid = waitpid(-1, NULL, WNOHANG); if ((pid == -1) || (pid == 0)) break; udev_done(pid); @@ -380,7 +380,7 @@ static void reap_kids() /* just read everything from the pipe and clear the flag, * the useful flags were set in the signal handler */ -static void user_sighandler() +static void user_sighandler(void) { int sig; while(1) { -- cgit v1.2.3-54-g00ecf