From c0b3b3af3e06a22531aefe4b04f6dfdb7e4678f9 Mon Sep 17 00:00:00 2001 From: herbrechtsmeier Date: Wed, 2 Apr 2025 14:41:44 +0200 Subject: [PATCH] hostnamed: fix incorrect usage of device_dmi (#36948) Fix incorrect usage of device_dmi in context_acquire_device_tree(). Follow-up for 3e91aed6c4e53824adddb5b8ad124ffecb0e0673. --- src/hostname/hostnamed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hostname/hostnamed.c b/src/hostname/hostnamed.c index d9ec55455fb..1f60423c5b5 100644 --- a/src/hostname/hostnamed.c +++ b/src/hostname/hostnamed.c @@ -281,7 +281,7 @@ static int context_acquire_device_tree(Context *c) { assert(c); assert(!c->device_tree); - r = sd_device_new_from_path(&c->device_dmi, "/proc/device-tree/"); + r = sd_device_new_from_path(&c->device_tree, "/proc/device-tree/"); if (ERRNO_IS_NEG_DEVICE_ABSENT(r)) { log_debug_errno(r, "Failed to open /proc/device-tree/ device, ignoring: %m"); return 0; -- 2.47.3