Return-Path: Delivered-To: new-httpd-archive@hyperreal.org Received: (qmail 11260 invoked by uid 6000); 21 Oct 1997 11:20:50 -0000 Received: (qmail 11251 invoked from network); 21 Oct 1997 11:20:47 -0000 Received: from gate-isdn.ukweb.com (194.152.65.149) by taz.hyperreal.org with SMTP; 21 Oct 1997 11:20:47 -0000 Received: from ecstasy.localnet [192.168.2.4] by gate-isdn.ukweb.com with smtp (Exim 1.61 #1) id 0xNcMv-0002nD-00; Tue, 21 Oct 1997 12:21:01 +0100 Date: Tue, 21 Oct 1997 11:20:12 +0000 (GMT) From: Paul Sutton To: new-httpd@hyperreal.org Subject: [BUG] NT version fails for CGI with ?arg Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: new-httpd-owner@apache.org Precedence: bulk Reply-To: new-httpd@apache.org There are two PRs about this. Any access to a CGI with a query string which does not contain either + or = fails (crashes Apache). This patch fixes it. The arguments to create_argv() seemed to be wrong. Since NT never uses suexec, there shouldn't be an initial path argument, and the args arguments were in the wrong place. So I've moved the path argument to the "argv0" argument, and the "args" argument to correct place. Was there any reason why the args to create_argv() were in a different order on NT from Unix? //pcs Index: util_script.c =================================================================== RCS file: /export/home/cvs/apachen/src/main/util_script.c,v retrieving revision 1.79 diff -u -r1.79 util_script.c --- util_script.c 1997/10/20 12:08:59 1.79 +++ util_script.c 1997/10/21 10:39:40 @@ -755,13 +755,13 @@ else { if (is_exe || is_binary) { pid = spawnve(_P_NOWAIT, r->filename, - create_argv(r->pool, argv0, NULL, NULL, r->args, - (void *) NULL), env); + create_argv(r->pool, NULL, NULL, NULL, argv0, + r->args), env); } else if (is_script) { ap_assert(0); pid = spawnve(_P_NOWAIT, interpreter + 2, - create_argv(r->pool, interpreter + 2, NULL, NULL, + create_argv(r->pool, NULL, NULL, NULL, r->filename, r->args), env); } else {