pidref: propagate critical errors in pidref_acquire_pidfd_id()

Follow-up for 571867ffa7.

Fixes CID#1612242.
This commit is contained in:
Yu Watanabe
2025-07-12 19:51:01 +09:00
parent b98d6bff23
commit b1eb6cc28b
+3 -1
View File
@@ -133,7 +133,9 @@ int pidref_set_pid_and_pidfd_id(
return r;
if (pidfd_id > 0) {
pidref_acquire_pidfd_id(&n);
r = pidref_acquire_pidfd_id(&n);
if (r < 0 && !ERRNO_IS_NEG_NOT_SUPPORTED(r))
return r;
if (n.fd_id != pidfd_id)
return -ESRCH;