NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/38466

The following reply was made to PR bin/38466; it has been noted by GNATS.

From: Arto Huusko <>
Subject: Re: bin/38466
Date: Wed, 27 May 2009 00:17:42 +0300

 httpd is again broken with cvsweb, and this bug should be reopened.
 httpd automatically appends index.html to any request ending with /.
 Apparently the new version appends the index.html unconditionally
 in function transform_request(), so process_cgi() has nothing to do
 with it this time around.
 I'm using the following simple workaround patch, which strips the
 index_html in process_cgi().
 Index: bozohttpd.c
 RCS file: /cvsroot/src/libexec/httpd/bozohttpd.c,v
 retrieving revision 1.15
 diff -r1.15 bozohttpd.c
 <       if (process_cgi(request))
  >       if (process_cgi(request, *isindex))
 Index: bozohttpd.h
 RCS file: /cvsroot/src/libexec/httpd/bozohttpd.h,v
 retrieving revision 1.11
 diff -r1.11 bozohttpd.h
 < extern        int     process_cgi(http_req *);
  > extern        int     process_cgi(http_req *, int isindex);
 Index: cgi-bozo.c
 RCS file: /cvsroot/src/libexec/httpd/cgi-bozo.c,v
 retrieving revision 1.14
 diff -r1.14 cgi-bozo.c
 < process_cgi(http_req *request)
  > process_cgi(http_req *request, int isindex)
  >       /* strip appended index.html */
  >       if (isindex)
  >               file[strlen(file) - strlen(index_html)] = 0;

Home | Main Index | Thread Index | Old Index