You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by tr...@apache.org on 2003/01/13 20:35:55 UTC

cvs commit: httpd-2.0/modules/filters mod_ext_filter.c

trawick     2003/01/13 11:35:55

  Modified:    .        CHANGES
               modules/filters mod_ext_filter.c
  Log:
  mod_ext_filter: Fix a problem building argument lists which
  occasionally caused exec to fail.
  
  The argument array passed to apr_proc_create() needs to have
  a NULL entry at the end.
  
  PR:		15491
  
  Revision  Changes    Path
  1.1023    +3 -0      httpd-2.0/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/CHANGES,v
  retrieving revision 1.1022
  retrieving revision 1.1023
  diff -u -r1.1022 -r1.1023
  --- CHANGES	9 Jan 2003 12:33:12 -0000	1.1022
  +++ CHANGES	13 Jan 2003 19:35:55 -0000	1.1023
  @@ -2,6 +2,9 @@
   
     [Remove entries to the current 2.0 section below, when backported]
   
  +  *) mod_ext_filter: Fix a problem building argument lists which 
  +     occasionally caused exec to fail.  PR 15491.  [Jeff Trawick]
  +
     *) Add mod_dav_lock - a generic subset of the DAV locking implementation.
        [Justin Erenkrantz]
   
  
  
  
  1.2       +3 -2      httpd-2.0/modules/filters/mod_ext_filter.c
  
  Index: mod_ext_filter.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/filters/mod_ext_filter.c,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- mod_ext_filter.c	14 Nov 2002 20:22:50 -0000	1.1
  +++ mod_ext_filter.c	13 Jan 2003 19:35:55 -0000	1.2
  @@ -222,9 +222,10 @@
       else
       {
           /* simple path */
  -        /* Allocate space for one argv pointer and parse the args. */
  -        filter->args = (char **)apr_palloc(p, sizeof(char *));
  +        /* Allocate space for two argv pointers and parse the args. */
  +        filter->args = (char **)apr_palloc(p, 2 * sizeof(char *));
           filter->args[0] = ap_getword_white(p, args);
  +        filter->args[1] = NULL; /* end of args */
       }
       if (!filter->args[0]) {
           return "Invalid cmd= parameter";