You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modules-dev@httpd.apache.org by César Leonardo Blum Silveira <ce...@gmail.com> on 2008/01/16 01:43:37 UTC

Fixups running twice

Hello,

I have written two test modules which only write messages to the
error_log. I have the following fixups on them:

mod_mod1.c:

static int mod1_fixups(request_rec *r) {
    ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, "mod1_fixups");
    return OK;
}

mod_mod2.c:

static int mod1_fixups(request_rec *r) {
    ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, "mod1_fixups");
    return OK;
}

For some reason which I still don't know, those fixups are being run
twice per request:

[Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod1_fixups
[Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod2_fixups
[Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod1_fixups
[Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod2_fixups

Is that the normal fixups behaviour?

Thank you,

-- 
César L. B. Silveira

Re: Fixups running twice

Posted by César Leonardo Blum Silveira <ce...@gmail.com>.
I figured it out already. A redirect was causing that behaviour.

On Jan 15, 2008 10:43 PM, César Leonardo Blum Silveira
<ce...@gmail.com> wrote:
> Hello,
>
> I have written two test modules which only write messages to the
> error_log. I have the following fixups on them:
>
> mod_mod1.c:
>
> static int mod1_fixups(request_rec *r) {
>     ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, "mod1_fixups");
>     return OK;
> }
>
> mod_mod2.c:
>
> static int mod1_fixups(request_rec *r) {
>     ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, "mod1_fixups");
>     return OK;
> }
>
> For some reason which I still don't know, those fixups are being run
> twice per request:
>
> [Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod1_fixups
> [Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod2_fixups
> [Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod1_fixups
> [Tue Jan 15 22:41:07 2008] [error] [client 127.0.0.1] mod2_fixups
>
> Is that the normal fixups behaviour?
>
> Thank you,
>
> --
> César L. B. Silveira
>



-- 
César L. B. Silveira