httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Lewis <...@joe-lewis.com>
Subject Re: problem getting per server config to work...
Date Thu, 04 Jan 2007 23:25:57 GMT
Drew Bertola wrote:
> Hi again,
>
> I'm finishing off my first module, but have some trouble with per server
> config.
>
> I have a simple virtualhost stanza with one added line that's causing a
> segfault when I run httpd -t.  The virtualhost looks like this (a
> configtest runs fine with the last line commented out):
>
>   
[snip]
>     AP_INIT_TAKE1("MYInsertFile",
>                   ap_set_string_slot,
>                   (void *) APR_OFFSETOF(my_insert_srv_cfg, insert_file),
>                   RSRC_CONF,
>                   "the path to the file to insert"),
>   
Okay.  The ap_set_* functions for setting variables ONLY work with 
per-directory configurations.  You will have to create your own set_* 
functions that alter the server-specific configuration element, as I 
don't know of any functions for that.  If it sets the wrong one (null 
pointer, etc), you get a seg-fault.  Hopefully this is beneficial to you.

Joe

Mime
View raw message