httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Schulze ...@bytecamp.net>
Subject Re: external redirect
Date Fri, 23 Jan 2009 10:10:11 GMT
Hi,

fkater@googlemail.com schrieb:
> 
> However, when I also try to set the new "Location" this
> always causes a segmentation fault:
> 
> char* uri=apr_pstrdup(r->pool,"http://localhost/abcdef");
> apr_table_setn(r->headers_out,"Location",uri);
> 
> return HTTP_MOVED_TEMPORARILY;
> 

Like others stated, it works this way, I used that in one module, too.

Maybe you should replace apr_table_setn() by apr_table_set(), which 
means that the memory for the entry will be allocated by apr_table_set() 
once more.

Rob


Mime
View raw message