From 7e45a75f96feabefff80dd94d140a84e4ae40888 Mon Sep 17 00:00:00 2001 From: Stanislav Ochotnicky Date: Tue, 1 Feb 2011 16:45:24 +0100 Subject: [PATCH] Fix bug 669259 (execve warning segfault) --- 0001-execve-path-warning.patch | 15 +++++++-------- apache-commons-daemon.spec | 5 ++++- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/0001-execve-path-warning.patch b/0001-execve-path-warning.patch index 25504ef..285f1ae 100644 --- a/0001-execve-path-warning.patch +++ b/0001-execve-path-warning.patch @@ -1,17 +1,17 @@ -From d4ac1b866785a0fd69abca5422b647453e96f7c3 Mon Sep 17 00:00:00 2001 +From 3c89eec3132a924721882f38b8ab06ab81ad2ee8 Mon Sep 17 00:00:00 2001 From: Stanislav Ochotnicky Date: Tue, 18 Jan 2011 14:46:21 +0100 Subject: [PATCH 1/3] execve path warning --- - src/native/unix/native/jsvc-unix.c | 10 ++++++++++ - 1 files changed, 10 insertions(+), 0 deletions(-) + src/native/unix/native/jsvc-unix.c | 9 +++++++++ + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/src/native/unix/native/jsvc-unix.c b/src/native/unix/native/jsvc-unix.c -index e3d9e89..7d50ea9 100644 +index e3d9e89..72d53c2 100644 --- a/src/native/unix/native/jsvc-unix.c +++ b/src/native/unix/native/jsvc-unix.c -@@ -966,6 +966,16 @@ int main(int argc, char *argv[]) +@@ -966,6 +966,15 @@ int main(int argc, char *argv[]) char *tmp = NULL; char *p1 = NULL; char *p2 = NULL; @@ -19,8 +19,7 @@ index e3d9e89..7d50ea9 100644 + /* We don't want to use a form of exec() that searches the + PATH, so require that argv[0] be either an absolute or + relative path. Error out if this isn't the case. */ -+ tmp=strchr(oldpath,'/'); -+ if (tmp==NULL) { ++ if (strchr(argv[0],'/') == NULL) { + log_error("JSVC re-exec requires execution with an absolute or relative path"); + return(1); + } @@ -29,5 +28,5 @@ index e3d9e89..7d50ea9 100644 /* * There is no need to change LD_LIBRARY_PATH -- -1.7.3.4 +1.7.3.5 diff --git a/apache-commons-daemon.spec b/apache-commons-daemon.spec index 34fe658..0109e0a 100644 --- a/apache-commons-daemon.spec +++ b/apache-commons-daemon.spec @@ -4,7 +4,7 @@ Name: apache-%{short_name} Version: 1.0.5 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Defines API to support an alternative invocation mechanism License: ASL 2.0 Group: Applications/System @@ -148,6 +148,9 @@ rm -rf $(readlink -f %{_javadocdir}/%{name}) %{_javadocdir}/%{name} || : %changelog +* Tue Feb 1 2011 Stanislav Ochotnicky - 1.0.5-2 +- Fix bug 669259 (execve warning segfault) + * Tue Jan 18 2011 Stanislav Ochotnicky - 1.0.5-1 - Update to latest version - Use maven 3 to build