summaryrefslogtreecommitdiff
path: root/src/core/device.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2013-10-14 06:10:14 +0200
committerLennart Poettering <lennart@poettering.net>2013-10-14 06:11:19 +0200
commit71fda00f320379f5cbee8e118848de98caaa229d (patch)
tree00a913086d70abadb1185e1343d97df860b0d612 /src/core/device.c
parent14bf2c9d375db6a4670bc0ef0e521e35a939a498 (diff)
list: make our list macros a bit easier to use by not requring type spec on each invocation
We can determine the list entry type via the typeof() gcc construct, and so we should to make the macros much shorter to use.
Diffstat (limited to 'src/core/device.c')
-rw-r--r--src/core/device.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/device.c b/src/core/device.c
index 25af2cb2d5..05950153d3 100644
--- a/src/core/device.c
+++ b/src/core/device.c
@@ -48,7 +48,7 @@ static void device_unset_sysfs(Device *d) {
/* Remove this unit from the chain of devices which share the
* same sysfs path. */
first = hashmap_get(UNIT(d)->manager->devices_by_sysfs, d->sysfs);
- LIST_REMOVE(Device, same_sysfs, first, d);
+ LIST_REMOVE(same_sysfs, first, d);
if (first)
hashmap_remove_and_replace(UNIT(d)->manager->devices_by_sysfs, d->sysfs, first->sysfs, first);
@@ -234,7 +234,7 @@ static int device_update_unit(Manager *m, struct udev_device *dev, const char *p
}
first = hashmap_get(m->devices_by_sysfs, sysfs);
- LIST_PREPEND(Device, same_sysfs, first, DEVICE(u));
+ LIST_PREPEND(same_sysfs, first, DEVICE(u));
r = hashmap_replace(m->devices_by_sysfs, DEVICE(u)->sysfs, first);
if (r < 0)