svn commit: trunk/uClibc/libc/unistd
vda at uclibc.org
vda at uclibc.org
Wed Jul 18 22:32:40 UTC 2007
Author: vda
Date: 2007-07-18 15:32:40 -0700 (Wed, 18 Jul 2007)
New Revision: 19163
Log:
execXp should go to next PATH dir on any error except ENOEXEC,
not just on ENOENT (in particular, on EPERM). At least glibc does so.
Fixing this.
Modified:
trunk/uClibc/libc/unistd/exec.c
Changeset:
Modified: trunk/uClibc/libc/unistd/exec.c
===================================================================
--- trunk/uClibc/libc/unistd/exec.c 2007-07-18 22:31:31 UTC (rev 19162)
+++ trunk/uClibc/libc/unistd/exec.c 2007-07-18 22:32:40 UTC (rev 19163)
@@ -235,11 +235,11 @@
if (strchr(path, '/')) {
execve(path, argv, __environ);
- CHECK_ENOEXEC:
if (errno == ENOEXEC) {
char **nargv;
EXEC_ALLOC_SIZE(size2) /* Do NOT add a semicolon! */
size_t n;
+ RUN_BIN_SH:
/* Need the dimension - 1. We omit counting the trailing
* NULL but we actually omit the first entry. */
for (n=0 ; argv[n] ; n++) {}
@@ -292,9 +292,9 @@
seen_small = 1;
- if (errno != ENOENT) {
+ if (errno == ENOEXEC) {
path = s;
- goto CHECK_ENOEXEC;
+ goto RUN_BIN_SH;
}
NEXT:
More information about the uClibc-cvs
mailing list