aboutsummaryrefslogtreecommitdiff
path: root/threadproc/unix/proc.c
diff options
context:
space:
mode:
authorRyan Bloom <rbb@apache.org>2000-10-18 06:09:09 +0000
committerRyan Bloom <rbb@apache.org>2000-10-18 06:09:09 +0000
commit08de65da91c17a11c3e5a4b28d3f62aaa08e4db7 (patch)
treef485072266cf5b3e9e5ecfbe8eb58e7a752373d9 /threadproc/unix/proc.c
parent1edaa83845e4c1546d8dc3693b56a26235e6776c (diff)
downloadapr-08de65da91c17a11c3e5a4b28d3f62aaa08e4db7.tar.gz
apr-08de65da91c17a11c3e5a4b28d3f62aaa08e4db7.zip
Fix piped logs in 2.0. This basically:
1) cleans up an annoying type that was getting in my way while I was trying to fix things. 2) Makes some of the allocations pcalloc instead of palloc 3) The arg array passed to create_process is a const *char *, not const *char []. PR: 6642 git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@60599 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'threadproc/unix/proc.c')
-rw-r--r--threadproc/unix/proc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/threadproc/unix/proc.c b/threadproc/unix/proc.c
index 5d21eeb02..b97abc80a 100644
--- a/threadproc/unix/proc.c
+++ b/threadproc/unix/proc.c
@@ -271,12 +271,11 @@ static apr_status_t limit_proc(apr_procattr_t *attr)
}
apr_status_t apr_create_process(apr_proc_t *new, const char *progname,
- char *const args[], char **env,
+ char *const *args, char **env,
apr_procattr_t *attr, apr_pool_t *cont)
{
int i;
- typedef const char *my_stupid_string;
- my_stupid_string *newargs;
+ const char **newargs;
new->in = attr->parent_in;
new->err = attr->parent_err;
@@ -323,7 +322,7 @@ apr_status_t apr_create_process(apr_proc_t *new, const char *progname,
i++;
}
newargs =
- (my_stupid_string *) apr_palloc(cont, sizeof (char *) * (i + 3));
+ (const char **) apr_palloc(cont, sizeof (char *) * (i + 3));
newargs[0] = SHELL_PATH;
newargs[1] = "-c";
i = 0;