Eric S. Johansson wrote:

>>   I guess I tested it before.. I would bet Apache was working in that
>>   way and that was the reason to remove the slash.
>
> ok, I'll try it out with apache to see what it does.

  Grand. Please, let me know if it is the same..

>>  > Another problem I found is that if the CGI returns a 404 error as
>>  > well as its own 404 display, I get the server's 404.  Maybe this is
>>  > a patchy specific but I was under the impression that the CGI
>>  > program had the option of returning its own data in the case of
>>  > errors detected.
>>
>>   0.4.29 already supports that behavior:
>>
>>   http://alobbs.com/pipermail/cherokee/2005-November/001071.html
>
> I remember that and assuming I did the test script right:
>
> #!/bin/bash
>
> echo "Status: 404"
> echo "Content-Type: text/html; charset=utf-8"
> echo
> echo
> echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
> "http://www.w3.org/TR/html4/loose.dtd";>'
> echo '<html>'
> echo '<head>'
> echo '<title>'
> echo '404 - page does not exist: thriip'
> echo '</title>'
> echo '</head>'
> echo '<body>'
> echo '<bold>I said, page does not exist!</bold>'
> echo '<p></body>'
> echo '</html>'
>
> shows how it fails with this config (in default):
>
> Directory / {
>     Handler cgi {
>       scriptalias /home/esj/akasha/x.sh
        ErrorHandler on
>     }
> }

  You forgot to tell the server you want this handler to manage the
  error responses as well.. :)

>>  > I've also noticed a similar problem with 500 errors.  Nothing from
>>  > standard error is placed into the log.  I'm currently debugging a
>>  > submit button problem.  I get a 500 error message and nothing else
>>  > so I am debugging relatively blind.  after spending a bit time
>>  > looking over the CGI handler, I'm relatively certain that the way
>>  > you handle the 404 and 500 error codes are part of the problem.
>>  >
>>  > not sure exactly how to fix it yet but that's where it lies.
>>
>>   The CHEROKEE_TRACE facility from HEAD might help. Anyway, if you
>>   provide me more information about what the problem, I will try to
>>   trace it back. :)
>
> n.p.  is CHEROKEE_TRACE a compile option?

  It is gonna be one of the new features in 0.5.0.  You have to
  execute ./configure with the --enable-trace flag, and it will
  compile the library with extra debugging information.

  If you want to trace something, you only need to set the
  CHEROKEE_TRACE variable.. for example:

  - CHEROKEE_TRACE="handler" /usr/sbin/cherokee. This will print
    debugging information about what are the handlers doing.

  - CHEROKEE_TRACE="read" /usr/sbin/cherokee. Idem, with the read()
    calls.

  - CHEROKEE_TRACE="all" /usr/sbin/cherokee. Lot of debug :-)

  .. the only weak point is how to figure out what the possible values
  of the environment variable are, but I will try to work it out.

--
Greetings, alo.
http://www.alobbs.com
_______________________________________________
Cherokee mailing list
Cherokee@lists.alobbs.com
http://www.alobbs.com/cgi-bin/mailman/listinfo/cherokee

Reply via email to