]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
namespace-util: refuse remote pidref in pidref_namespace_open()
authorYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 22 Nov 2024 17:29:17 +0000 (02:29 +0900)
committerMike Yuan <me@yhndnzj.com>
Sat, 4 Jan 2025 16:07:59 +0000 (17:07 +0100)
src/basic/namespace-util.c

index 332e8cdfd5de64a58edef5ac7e426dee08a89a58..f4b29a49ac91b1f3a31c390af94f99f2dc2cf144 100644 (file)
@@ -62,6 +62,9 @@ int pidref_namespace_open(
 
         assert(pidref_is_set(pidref));
 
+        if (pidref_is_remote(pidref))
+                return -EREMOTE;
+
         if (ret_pidns_fd) {
                 const char *pidns;