I encountered a problem using Apache::StatINC with modules that have the
directive:

use base qw( SomeClass );


The error I got was the following:


[Mon Dec  6 07:35:47 1999] [error] Inherited %FIELDS can't override existing %FIELDS 
at /usr/lib/perl5/5.0050 3/base.pm line 73
BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.005/HKMDB/Job.pm line 
10.


After messing a bit with Apache::StatINC I found that the solution was to
'use' the module again rather than requiring it.

I have a patch attached to do this.  I'm not sure if this is really the
right solution though.


-Dave


*** Sb  Mon Dec  6 07:45:52 1999
--- StatINC.pm  Mon Dec  6 07:46:10 1999
***************
*** 26,32 ****
                 $class->Apache::Symbol::undef_functions( undef, 1 );
            }
            delete $INC{$key};
!           require $key;
            warn "Apache::StatINC: process $$ reloading $key\n"
                  if $DEBUG;
        }
--- 26,33 ----
                 $class->Apache::Symbol::undef_functions( undef, 1 );
            }
            delete $INC{$key};
! #         require $key;
!           eval "use $key;";
            warn "Apache::StatINC: process $$ reloading $key\n"
                  if $DEBUG;
        }




/*==================
www.urth.org
We await the New Sun
==================*/

Reply via email to