Daniel B. Hemmerich wrote:
Stas Bekman wrote:

Who generates this "Can't locate" message? Normal die() messages should already be prefixed.


This is occuring during a require, such as:

require '/www/path/goes/here//config.pl';
>
The script itself is poorly written since it should be doing its own -e check prior to requiring it (in my opinion).

Daniel, as we have talked before I remember you're using mp1, but in the future please always submit a complete bug report, so we know more about your setup. Please see: http://perl.apache.org/bugs/

In mp2 you will get a proper logging on this type of failure. In mp1, you could either use this technique:

  eval { require ... };
  if ($@) {
     # handle the exception here
     # $@ contains the error message
  }

or:

  local $SIG{__DIE__} = sub { # handle the exception here,
                              # $_[0] contains the error message }
  require ...;

in your exception handler you can fixup the logging format.

--
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

Reply via email to