aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'tests/openat-2.sh')
-rwxr-xr-xtests/openat-2.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/openat-2.sh b/tests/openat-2.sh
new file mode 100755
index 0000000..b615c2d
--- /dev/null
+++ b/tests/openat-2.sh
@@ -0,0 +1,9 @@
+#!/bin/sh
+# verify openat("") returns ENOENT in various ways #346929
+
+set -e
+openat-0 -1,ENOENT .:O_DIRECTORY '' O_RDONLY 0
+openat-0 -1,ENOENT .:O_DIRECTORY '' 'O_CREAT|O_WRONLY' 0
+
+openat-0 -1,ENOENT -3 '' O_RDONLY 0
+openat-0 -1,ENOENT -3 '' 'O_CREAT|O_WRONLY' 0