The attached test.pl (with the attached ModuleOne.pm and ModuleTwo.pm) produces two warnings when reloaded following a ModPerl::Util::unload_package() call as per Apache2::Reload - one about a prototype mismatch for a function imported by the reloaded module, and one about a subroutine redefinition for a function defined by the reloaded module:
C:\Temp>C:\perl5\bin\perl test.pl Loading... Unloading... Reloading... Prototype mismatch: sub ModuleOne::FunctionTwo: none vs ($) at C:/perl5/lib/Exporter.pm line 64. at ModuleOne.pm line 4 Subroutine FunctionOne redefined at ModuleOne.pm line 5. I believe this happens because the entries for the symbols that have been undef'ed are still left in the symbol table stash. Removing those entries from the stash after undef'ing them (as in the attached reload.patch) gets rid of the warnings which are otherwise filling up my error.log! Does anyone know of some reason why this is not being done? If not then I'll commit this patch soon...
test.pl
Description: test.pl
ModuleOne.pm
Description: ModuleOne.pm
ModuleTwo.pm
Description: ModuleTwo.pm
reload.patch
Description: reload.patch
--------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@perl.apache.org For additional commands, e-mail: dev-h...@perl.apache.org