Mercurial > hg > release > icedtea6-1.5
view patches/openjdk/rename-execvpe.patch @ 1580:b0bb743c12d1
* Makefile.am (ICEDTEA_PATCHES): Add rename-execvpe.patch,
icedtea-6897844-xshm.patch,
icedtea-linux-separate-debuginfo.patch.
author | aph |
---|---|
date | Thu, 17 Dec 2009 16:24:09 +0000 |
parents | |
children |
line wrap: on
line source
# HG changeset patch # User martin # Date 1248923453 25200 # Node ID 0f6e8cdc0cbab5221e81b7d25f1b869bd6ecf34a # Parent ac4f0c58f4c771267f1b5c65a8cf5bf2722a881b [mq]: rename-execvpe diff --git a/src/solaris/native/java/lang/UNIXProcess_md.c b/src/solaris/native/java/lang/UNIXProcess_md.c --- openjdk/jdk/src/solaris/native/java/lang/UNIXProcess_md.c +++ openjdk/jdk/src/solaris/native/java/lang/UNIXProcess_md.c @@ -423,9 +423,20 @@ return -1; } -/* execvpe should have been included in the Unix standards. */ +/** + * 'execvpe' should have been included in the Unix standards, + * and is a GNU extension in glibc 2.10. + * + * JDK_execvpe is identical to execvp, except that the child environment is + * specified via the 3rd argument instead of being inherited from environ. + * + * This implementation of JDK_execvpe does not work if memory is shared + * with the parent, when using vfork(2), or clone(2) with CLONE_VM. + */ static int -execvpe(const char *file, const char *const argv[], const char *const envp[]) +JDK_execvpe(const char *file, + const char *const argv[], + const char *const envp[]) { /* This is one of the rare times it's more portable to declare an * external symbol explicitly, rather than via a system header. @@ -601,7 +612,7 @@ if (fcntl(FAIL_FILENO, F_SETFD, FD_CLOEXEC) == -1) goto WhyCantJohnnyExec; - execvpe(argv[0], argv, envv); + JDK_execvpe(argv[0], argv, envv); WhyCantJohnnyExec: /* We used to go to an awful lot of trouble to predict whether the