perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Clinton Gormley <cl...@traveljury.com >
Subject PerlConfigRequire and die
Date Mon, 23 Feb 2009 14:32:40 GMT
Hiya

I'm using PerlConfigRequire to load my Perl application, which also sets
up the VirtualHost's using $r->add_config()

The problem is, if one my modules has a compile time error, instead of
getting the real error message, I get something like this:

---------------------------------------------------------
Syntax error on line 266 of /opt/apache/conf/httpd.conf:
`l\xa6\x02
---------------------------------------------------------

I realise that PerlPostConfigRequire should normally be used in
preference to PerlConfigRequire, but because I need to alter apache's
config, this isn't an option.

If I change my code in startup.pl from:

  load_application();
  1;

to:
   eval {load_application(); 1} || print STDERR $@;
   1;

then I see the proper error message, but apache starts anyway.

Die'ing or returning 0 both result in this weird error.

Is there any way I can:
 - cause the error to be reported properly
 - force apache not to start

thanks

Clint


Mime
View raw message