From 9a7fb1a060a7f493c9f6eec55d1c35cd83f55496 Mon Sep 17 00:00:00 2001 From: Antonio SJ Musumeci Date: Mon, 15 Dec 2025 00:36:59 -0600 Subject: [PATCH] tests.cpp --- tests/tests.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/tests.cpp b/tests/tests.cpp index 0eebf7c5..054b8f4b 100644 --- a/tests/tests.cpp +++ b/tests/tests.cpp @@ -307,6 +307,7 @@ static void test_rmdir() { + int rv; int root_fd; int dir_fd; @@ -314,6 +315,9 @@ test_rmdir() TEST_CHECK(root_fd >= 0); dir_fd = mkdirat(root_fd,"test-dir",0777); TEST_CHECK(dir_fd >= 0); + dir_fd = openat(root_fd,"test-dir",O_DIRECTORY); + + rv = unlinkat(dir_fd, close(dir_fd);