X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fcore%2Fdevice.c;h=068578dc829a82f8f6ea85c0157c11f2a8140d1a;hb=79008bddf679a5e0900369950eb346c9fa687107;hp=0f28a168740de09d95bb46c2cbc4165ea11d604a;hpb=b2fadec6048adb3596f2633cb7fe7a49f5937a18;p=elogind.git diff --git a/src/core/device.c b/src/core/device.c index 0f28a1687..068578dc8 100644 --- a/src/core/device.c +++ b/src/core/device.c @@ -98,7 +98,7 @@ static void device_set_state(Device *d, DeviceState state) { d->state = state; if (state != old_state) - log_debug_unit(UNIT(d)->id, + log_unit_debug(UNIT(d)->id, "%s changed %s -> %s", UNIT(d)->id, device_state_to_string(old_state), device_state_to_string(state)); @@ -249,7 +249,7 @@ static int device_add_udev_wants(Unit *u, struct udev_device *dev) { return r; } if (!isempty(state)) - log_warning_unit(u->id, "Property %s on %s has trailing garbage, ignoring.", + log_unit_warning(u->id, "Property %s on %s has trailing garbage, ignoring.", property, strna(udev_device_get_syspath(dev))); return 0; @@ -304,7 +304,7 @@ static int device_update_unit(Manager *m, struct udev_device *dev, const char *p goto fail; } - r = hashmap_ensure_allocated(&m->devices_by_sysfs, string_hash_func, string_compare_func); + r = hashmap_ensure_allocated(&m->devices_by_sysfs, &string_hash_ops); if (r < 0) goto fail; @@ -517,7 +517,7 @@ static int device_following_set(Unit *u, Set **_set) { return 0; } - set = set_new(NULL, NULL); + set = set_new(NULL); if (!set) return -ENOMEM;