Loading ...
Sorry, an error occurred while loading the content.
 

Why isn't REDIRECT_ERROR_NOTES set in modperl 2?

Expand Messages
  • Rando Christensen
    The last thing I need to do in order to be able to migrate to apache2 is to figure this out. Under apache1.3 and modperl, the error-notes would be properly set
    Message 1 of 6 , May 1, 2004
      The last thing I need to do in order to be able to migrate to apache2
      is to figure this out.

      Under apache1.3 and modperl, the error-notes would be properly set to
      whatever we die() with, just like it would under apache1.3 and a cgi
      script.

      However, under the newer modperl, this doesn't get set. (Though it does
      work as I expect under Apache2 with a cgi script instead of mod_perl)
      What am I doing wrong, and how do I fix this?

      --
      < Rando Christensen | eyez@... >

      --
      Report problems: http://perl.apache.org/bugs/
      Mail list info: http://perl.apache.org/maillist/modperl.html
      List etiquette: http://perl.apache.org/maillist/email-etiquette.html
    • Stas Bekman
      ... I suppose we just haven t got around implementing it yet in the plain handlers (Registry has it since 1.99_05). Does the following patch does the trick for
      Message 2 of 6 , May 2, 2004
        Rando Christensen wrote:
        > The last thing I need to do in order to be able to migrate to apache2
        > is to figure this out.
        >
        > Under apache1.3 and modperl, the error-notes would be properly set to
        > whatever we die() with, just like it would under apache1.3 and a cgi
        > script.
        >
        > However, under the newer modperl, this doesn't get set. (Though it does
        > work as I expect under Apache2 with a cgi script instead of mod_perl)
        > What am I doing wrong, and how do I fix this?

        I suppose we just haven't got around implementing it yet in the plain handlers
        (Registry has it since 1.99_05). Does the following patch does the trick for
        you, Rando?

        Index: src/modules/perl/modperl_callback.c
        ===================================================================
        RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_callback.c,v
        retrieving revision 1.70
        diff -u -r1.70 modperl_callback.c
        --- src/modules/perl/modperl_callback.c 4 Mar 2004 06:01:06 -0000 1.70
        +++ src/modules/perl/modperl_callback.c 2 May 2004 19:56:30 -0000
        @@ -142,6 +142,12 @@
        status = HTTP_INTERNAL_SERVER_ERROR;
        }

        + if (status == HTTP_INTERNAL_SERVER_ERROR) {
        + if (r && r->notes) {
        + apr_table_set(r->notes, "error-notes", SvPV_nolen(ERRSV));
        + }
        + }
        +
        return status;
        }



        __________________________________________________________________
        Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
        http://stason.org/ mod_perl Guide ---> http://perl.apache.org
        mailto:stas@... http://use.perl.org http://apacheweek.com
        http://modperlbook.org http://apache.org http://ticketmaster.com

        --
        Report problems: http://perl.apache.org/bugs/
        Mail list info: http://perl.apache.org/maillist/modperl.html
        List etiquette: http://perl.apache.org/maillist/email-etiquette.html
      • Rando Christensen
        On Sun, 02 May 2004 12:58:26 -0700, Stas Bekman wrote: ... Perfectly. Thank you. -- -- Report problems:
        Message 3 of 6 , May 2, 2004
          On Sun, 02 May 2004 12:58:26 -0700, Stas Bekman wrote:>
          > I suppose we just haven't got around implementing it yet in the plain
          > handlers (Registry has it since 1.99_05). Does the following patch
          > does the trick for you, Rando?

          Perfectly. Thank you.

          --
          < Rando Christensen | eyez@... >

          --
          Report problems: http://perl.apache.org/bugs/
          Mail list info: http://perl.apache.org/maillist/modperl.html
          List etiquette: http://perl.apache.org/maillist/email-etiquette.html
        • Stas Bekman
          ... Does it work? I haven t tested it. We need to write a proper test before I can commit it. There is some test in mp1, which can probably be ported (or one
          Message 4 of 6 , May 2, 2004
            Rando Christensen wrote:
            > On Sun, 02 May 2004 12:58:26 -0700, Stas Bekman wrote:>
            >
            >>I suppose we just haven't got around implementing it yet in the plain
            >>handlers (Registry has it since 1.99_05). Does the following patch
            >>does the trick for you, Rando?
            >
            >
            > Perfectly. Thank you.

            Does it work? I haven't tested it. We need to write a proper test before I can
            commit it. There is some test in mp1, which can probably be ported (or one
            written from scratch).

            __________________________________________________________________
            Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
            http://stason.org/ mod_perl Guide ---> http://perl.apache.org
            mailto:stas@... http://use.perl.org http://apacheweek.com
            http://modperlbook.org http://apache.org http://ticketmaster.com

            --
            Report problems: http://perl.apache.org/bugs/
            Mail list info: http://perl.apache.org/maillist/modperl.html
            List etiquette: http://perl.apache.org/maillist/email-etiquette.html
          • Rando Christensen
            ... Yes, it s applied and running on my test server, and seems to work exactly as it did under modperl 1. -- --
            Message 5 of 6 , May 2, 2004
              On Sun, 02 May 2004 13:42:11 -0700, Stas Bekman wrote:

              > Does it work? I haven't tested it. We need to write a proper test
              > before I can commit it. There is some test in mp1, which can probably
              > be ported (or one written from scratch).

              Yes, it's applied and running on my test server, and seems to work
              exactly as it did under modperl 1.

              --
              < Rando Christensen | eyez@... >

              --
              Report problems: http://perl.apache.org/bugs/
              Mail list info: http://perl.apache.org/maillist/modperl.html
              List etiquette: http://perl.apache.org/maillist/email-etiquette.html
            • Stas Bekman
              ... Thanks Rando! __________________________________________________________________ Stas Bekman JAm_pH ------ Just Another mod_perl Hacker
              Message 6 of 6 , May 2, 2004
                Rando Christensen wrote:
                > On Sun, 02 May 2004 13:42:11 -0700, Stas Bekman wrote:
                >
                >
                >>Does it work? I haven't tested it. We need to write a proper test
                >>before I can commit it. There is some test in mp1, which can probably
                >>be ported (or one written from scratch).
                >
                >
                > Yes, it's applied and running on my test server, and seems to work
                > exactly as it did under modperl 1.

                Thanks Rando!
                __________________________________________________________________
                Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
                http://stason.org/ mod_perl Guide ---> http://perl.apache.org
                mailto:stas@... http://use.perl.org http://apacheweek.com
                http://modperlbook.org http://apache.org http://ticketmaster.com

                --
                Report problems: http://perl.apache.org/bugs/
                Mail list info: http://perl.apache.org/maillist/modperl.html
                List etiquette: http://perl.apache.org/maillist/email-etiquette.html
              Your message has been successfully submitted and would be delivered to recipients shortly.