]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
stat-util: O_NOCTTY is nop with O_PATH
authorMike Yuan <me@yhndnzj.com>
Mon, 19 Jan 2026 00:15:18 +0000 (01:15 +0100)
committerMike Yuan <me@yhndnzj.com>
Mon, 19 Jan 2026 12:33:27 +0000 (13:33 +0100)
src/basic/stat-util.c

index 5113d0459bae7b81003528fe56231b8b26921b2a..628d99ac5a685985f437434b2bd3c5d38709e786 100644 (file)
@@ -264,7 +264,7 @@ int xstatfsat(int dir_fd, const char *path, struct statfs *ret) {
         assert(ret);
 
         if (!isempty(path)) {
-                fd = xopenat(dir_fd, path, O_PATH|O_CLOEXEC|O_NOCTTY);
+                fd = xopenat(dir_fd, path, O_PATH|O_CLOEXEC);
                 if (fd < 0)
                         return fd;
                 dir_fd = fd;