From 8703a508355bacf3522d4f41455a238b3d866484 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 7 Jan 2025 10:12:10 +0100 Subject: [PATCH] coredump: acquire further attributes via pidref rather than pid --- src/coredump/coredump.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/coredump/coredump.c b/src/coredump/coredump.c index c9f6a276e5f..1125298786c 100644 --- a/src/coredump/coredump.c +++ b/src/coredump/coredump.c @@ -1385,10 +1385,10 @@ static int gather_pid_metadata_from_procfs(struct iovec_wrapper *iovw, Context * if (cg_pid_get_user_unit(pid, &t) >= 0) (void) iovw_put_string_field_free(iovw, "COREDUMP_USER_UNIT=", t); - if (sd_pid_get_session(pid, &t) >= 0) + if (cg_pidref_get_session(&context->pidref, &t) >= 0) (void) iovw_put_string_field_free(iovw, "COREDUMP_SESSION=", t); - if (sd_pid_get_owner_uid(pid, &owner_uid) >= 0) { + if (cg_pidref_get_owner_uid(&context->pidref, &owner_uid) >= 0) { r = asprintf(&t, UID_FMT, owner_uid); if (r > 0) (void) iovw_put_string_field_free(iovw, "COREDUMP_OWNER_UID=", t); -- 2.47.3