summaryrefslogtreecommitdiff
path: root/src/logind-dbus.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2011-07-13 20:11:23 +0200
committerLennart Poettering <lennart@poettering.net>2011-07-13 20:11:23 +0200
commit309c2a2ce95aae54879b4957d113f03608530c15 (patch)
treeefc2e41a6e339eb2299e37b2a1fd77dfd3e7f933 /src/logind-dbus.c
parentf2994ddbf9af6be52dc962332bbaeb7e2b1f3bde (diff)
loginctl: use new udev_device_has_tag() call from libudev where applicable
Diffstat (limited to 'src/logind-dbus.c')
-rw-r--r--src/logind-dbus.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/src/logind-dbus.c b/src/logind-dbus.c
index 16dbd3664c..e0855f4cf8 100644
--- a/src/logind-dbus.c
+++ b/src/logind-dbus.c
@@ -550,23 +550,6 @@ fail:
return r;
}
-static bool device_has_tag(struct udev_device *d, const char *tag) {
- struct udev_list_entry *first, *item;
-
- assert(d);
- assert(tag);
-
- /* FIXME */
- udev_device_get_is_initialized(d);
-
- first = udev_device_get_tags_list_entry(d);
- udev_list_entry_foreach(item, first)
- if (streq(udev_list_entry_get_name(item), tag))
- return true;
-
- return false;
-}
-
static int trigger_device(Manager *m, const char *prefix) {
struct udev_enumerate *e;
struct udev_list_entry *first, *item;
@@ -628,7 +611,7 @@ static int attach_device(Manager *m, const char *seat, const char *sysfs) {
if (!d)
return -ENODEV;
- if (!device_has_tag(d, "seat")) {
+ if (!udev_device_has_tag(d, "seat")) {
r = -ENODEV;
goto finish;
}