You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Rob Hartill <ro...@imdb.com> on 1996/12/04 18:22:07 UTC
Re: WWW Form Bug Report: "httpd dumps core in mod_include module" on Solaris 2.x
hi,
andy@demos.net wrote:
>
>Submitter: andy@demos.net
>Operating system: Solaris 2.x, version:
>Version of Apache Used: 1.1.1 and 1.2b1
>Extra Modules used: mod_status
>URL exhibiting problem:
>
>Symptoms:
>--
> I've already reported this problem in 1.1.1 when
>pfclose() is called with invalid argument, but the
>bug is still here :(((
Ahh, sorry.
>Here is a patch:
>
>*** mod_include.c.orig Wed Dec 4 18:59:38 1996
>--- mod_include.c Wed Dec 4 19:01:14 1996
>***************
>*** 122,128 ****
> { \
> int i = getc(f); \
> if(feof(f) || ferror(f) || (i == -1)) { \
>! pfclose(p,f); \
> return r; \
> } \
> c = (char)i; \
>--- 122,128 ----
> { \
> int i = getc(f); \
> if(feof(f) || ferror(f) || (i == -1)) { \
>! if(p) pfclose(p, f); else fclose(f); \
> return r; \
> } \
> c = (char)i; \
>***************
>*** 140,146 ****
>
> p=0;
> while(1) {
>! GET_CHAR(in,c,1,r->pool);
> if(c == str[p]) {
> if((++p) == l)
> return 0;
>--- 140,146 ----
>
> p=0;
> while(1) {
>! GET_CHAR(in,c,1,r?r->pool:NULL);
> if(c == str[p]) {
> if((++p) == l)
> return 0;
>
>--
>
>Backtrace:
>--
>
>--
>
--
Rob Hartill. Internet Movie Database Ltd. http://www.imdb.com/
Re: WWW Form Bug Report: "httpd dumps core in mod_include module" on Solaris 2.x
Posted by Brian Behlendorf <br...@organic.com>.
Andy, could you provide a situation where this was causing core dumps, so we
can test out whether this actually fixes a problem? I see other places in the
code where arguments to pfclose aren't checked, so I'm just curious as to why
this would cause problems...
Brian
> andy@demos.net wrote:
> >
> >Submitter: andy@demos.net
> >Operating system: Solaris 2.x, version:
> >Version of Apache Used: 1.1.1 and 1.2b1
> >Extra Modules used: mod_status
> >URL exhibiting problem:
> >
> >Symptoms:
> >--
> > I've already reported this problem in 1.1.1 when
> >pfclose() is called with invalid argument, but the
> >bug is still here :(((
> >
> >Here is a patch:
> >
> >*** mod_include.c.orig Wed Dec 4 18:59:38 1996
> >--- mod_include.c Wed Dec 4 19:01:14 1996
> >***************
> >*** 122,128 ****
> > { \
> > int i = getc(f); \
> > if(feof(f) || ferror(f) || (i == -1)) { \
> >! pfclose(p,f); \
> > return r; \
> > } \
> > c = (char)i; \
> >--- 122,128 ----
> > { \
> > int i = getc(f); \
> > if(feof(f) || ferror(f) || (i == -1)) { \
> >! if(p) pfclose(p, f); else fclose(f); \
> > return r; \
> > } \
> > c = (char)i; \
> >***************
> >*** 140,146 ****
> >
> > p=0;
> > while(1) {
> >! GET_CHAR(in,c,1,r->pool);
> > if(c == str[p]) {
> > if((++p) == l)
> > return 0;
> >--- 140,146 ----
> >
> > p=0;
> > while(1) {
> >! GET_CHAR(in,c,1,r?r->pool:NULL);
> > if(c == str[p]) {
> > if((++p) == l)
> > return 0;
--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--
brian@organic.com www.apache.org hyperreal.com http://www.organic.com/JOBS