httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ras...@madhaus.utcs.utoronto.ca
Subject Re: vote status (patch 78)
Date Fri, 16 Feb 1996 14:42:15 GMT
> Ahh, you mean that mod_actions.c was dependant on 78 and that I
> should veto that too? 8-)
> 
> I think that not breaking existing features is more important than
> enabling new features. You need to check every instance of
> internal_redirect() -- the custom error response is certainly one case
> where the method has to be reset to GET.
> 
> Whilst you are updating the patch, you might as well change the lines like
>     new->method = pstrdup(r->pool, r->method);
> to be
>     new->method = r->method
> 
> and 
>     r->method = pstrdup(r->pool, "GET");
> to
>     r->method = GET";

Actually, I didn't write that patch that is on hyperreal.  I did write
that exact same patch myself before discovering it was already done,
and I didn't have the pstrdup()'s in there.  Looks to me like the memory
is already allocated.  

How about adding a new function which handles the case where the
inherited method should be set to GET.  Something like:

   internal_redirect_get(char *new_uri, request_rec *r)

There are only 5 places where internal_redirect() is called.  mod_actions, 
mod_cgi, mod_dir, mod_negotiation and once from http_request itself to 
do the custom error message response.  4 of these calls require that the
method be inherited.  Only the http_request call needs it to be forced
to GET.  I propose that the call in http_request.c be changed to
internal_redirect_get() and this function be added to http_request.c.

--
Rasmus Lerdorf
rasmus@madhaus.utcs.utoronto.ca

Mime
View raw message