diff options
author | sjoerd@spring.luon.net <sjoerd@spring.luon.net> | 2004-04-08 18:48:56 -0700 |
---|---|---|
committer | Greg KH <gregkh@suse.de> | 2005-04-26 21:35:15 -0700 |
commit | 4b06c852cb7da274b50f665a75367f901d8064ae (patch) | |
tree | 1452478c34cf0c0d1656dd58bff3ef5dc3d4196f /extras | |
parent | 1321258af575f1e704aedfb3b6ed8aa341632a50 (diff) |
[PATCH] DEVNODE -> DEVNAME transition fixes
It seems that the transition from DEVNODE to DEVNAME wasn't done
everywhere. This broke udev_dbus for me.
Attached patch does the transition in the places it wasn't done yet.
Diffstat (limited to 'extras')
-rw-r--r-- | extras/dbus/udev_dbus.c | 24 | ||||
-rw-r--r-- | extras/selinux/udev_selinux.c | 10 |
2 files changed, 17 insertions, 17 deletions
diff --git a/extras/dbus/udev_dbus.c b/extras/dbus/udev_dbus.c index 955a3dbb49..e99e92ec87 100644 --- a/extras/dbus/udev_dbus.c +++ b/extras/dbus/udev_dbus.c @@ -80,10 +80,10 @@ static void sysbus_connect(void) /** Send out a signal that a device node is created * - * @param devnode name of the device node, e.g. /dev/sda1 + * @param devname name of the device node, e.g. /dev/sda1 * @param path Sysfs path of device */ -static void sysbus_send_create(const char *devnode, const char *path) +static void sysbus_send_create(const char *devname, const char *path) { DBusMessage* message; DBusMessageIter iter; @@ -94,7 +94,7 @@ static void sysbus_send_create(const char *devnode, const char *path) "NodeCreated"); dbus_message_iter_init(message, &iter); - dbus_message_iter_append_string(&iter, devnode); + dbus_message_iter_append_string(&iter, devname); dbus_message_iter_append_string(&iter, path); if ( !dbus_connection_send(sysbus_connection, message, NULL) ) @@ -107,10 +107,10 @@ static void sysbus_send_create(const char *devnode, const char *path) /** Send out a signal that a device node is deleted * - * @param devnode Name of the device node, e.g. /udev/sda1 + * @param devname Name of the device node, e.g. /udev/sda1 * @param path Sysfs path of device */ -static void sysbus_send_remove(const char *devnode, const char *path) +static void sysbus_send_remove(const char *devname, const char *path) { DBusMessage* message; DBusMessageIter iter; @@ -121,7 +121,7 @@ static void sysbus_send_remove(const char *devnode, const char *path) "NodeDeleted"); dbus_message_iter_init(message, &iter); - dbus_message_iter_append_string(&iter, devnode); + dbus_message_iter_append_string(&iter, devname); dbus_message_iter_append_string(&iter, path); if ( !dbus_connection_send(sysbus_connection, message, NULL) ) @@ -136,7 +136,7 @@ int main(int argc, char *argv[], char *envp[]) { char *action; char *devpath; - char *devnode; + char *devname; int retval = 0; init_logging("udev_dbus"); @@ -155,17 +155,17 @@ int main(int argc, char *argv[], char *envp[]) dbg("no devpath?"); goto exit; } - devnode = get_devnode(); - if (!devnode) { - dbg("no devnode?"); + devname = get_devname(); + if (!devname) { + dbg("no devname?"); goto exit; } if (strcmp(action, "add") == 0) { - sysbus_send_create(devnode, devpath); + sysbus_send_create(devname, devpath); } else { if (strcmp(action, "remove") == 0) { - sysbus_send_remove(devnode, devpath); + sysbus_send_remove(devname, devpath); } else { dbg("unknown action '%s'", action); retval = -EINVAL; diff --git a/extras/selinux/udev_selinux.c b/extras/selinux/udev_selinux.c index bbbdd6ba53..df23d9e6a7 100644 --- a/extras/selinux/udev_selinux.c +++ b/extras/selinux/udev_selinux.c @@ -48,7 +48,7 @@ int main(int argc, char *argv[], char *envp[]) { char *action; char *devpath; - char *devnode; + char *devname; int retval = 0; init_logging("udev_selinux"); @@ -58,14 +58,14 @@ int main(int argc, char *argv[], char *envp[]) dbg("no action?"); goto exit; } - devnode = get_devnode(); - if (!devnode) { - dbg("no devnode?"); + devname = get_devname(); + if (!devname) { + dbg("no devname?"); goto exit; } if (strcmp(action, "add") == 0) - selinux_add_node(devnode); + selinux_add_node(devname); exit: return retval; |