Hi,
> 
> > 
> > We are receiving "ERR 12" open errors from Embperl instead of
> >  "404 Not Found" errors.
> >  Is anyone having the same problem?  Does anyone know what is wrong 
> > with our configuration?
> > 
> 

The attached patch should solve the problem

Gerald


 
** Virus checked by BB-5000 Mailfilter ** 
Index: embperl.h
===================================================================
RCS file: /home/cvs/embperl/embperl.h,v
retrieving revision 1.36
diff -r1.36 embperl.h
98a99
>     rcTokenNotFound,  
Index: epio.c
===================================================================
RCS file: /home/cvs/embperl/epio.c,v
retrieving revision 1.31
diff -r1.31 epio.c
603a604,607
>         if (errno == EACCES)
>             return rcForbidden ;
>         else if (errno == ENOENT)
>             return rcNotFound ;
Index: epmain.c
===================================================================
RCS file: /home/cvs/embperl/epmain.c,v
retrieving revision 1.141
diff -r1.141 epmain.c
749c750,751
< static int GenerateErrorPage (/*i/o*/ register req * r)
---
> static int GenerateErrorPage (/*i/o*/ register req * r,
>                                     /*in*/  int    rc)
755a758,763
> #ifdef APACHE
>       if (r -> pApacheReq && rc >= 400)
>           r -> pApacheReq -> status = rc ;
>         else
>             r -> pApacheReq -> status = 500 ;
> #endif
804,807d811
< #ifdef APACHE
<       if (r -> pApacheReq)
<           r -> pApacheReq -> status = 500 ;
< #endif
1152c1156
<         GenerateErrorPage (r) ;
---
>         GenerateErrorPage (r, rc) ;
Index: Embperl/App.pm
===================================================================
RCS file: /home/cvs/embperl/Embperl/App.pm,v
retrieving revision 1.6
diff -r1.6 App.pm
83a84
>     my $status      = $req_rec?$req_rec -> status:0 ;
94c95,106
<     Embperl::Req::output ($r,"<H1>Internal Server Error</H1>\r\n") ;
---
>     if ($status == 403)
>         {
>         Embperl::Req::output ($r,"<H1>Forbidden</H1>\r\n") ;
>         }
>     elsif ($status == 404)
>         {
>         Embperl::Req::output ($r,"<H1>Not Found</H1>\r\n") ;
>         }
>     else
>         {
>         Embperl::Req::output ($r,"<H1>Internal Server Error</H1>\r\n") ;
>         }



** Virus checked by BB-5000 Mailfilter **

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to