.
[glibc/history.git] / posix / tst-execve1.c
blob356610f6353329ae4a61f71df0bcbd18e998414e
1 #include <errno.h>
2 #include <stdio.h>
3 #include <unistd.h>
5 static int
6 do_test (void)
8 char *argv[] = { (char *) "does-not-exist", NULL };
9 char *envp[] = { (char *) "FOO=BAR", NULL };
10 errno = 0;
11 execve (argv[0], argv, envp);
13 if (errno != ENOENT)
15 printf ("errno = %d (%m), expected ENOENT\n", errno);
16 return 1;
19 return 0;
22 #define TEST_FUNCTION do_test ()
23 #include "../test-skeleton.c"