On Sun, 7 May 2000, Richard Chen wrote:
> Instead of the line
> undef &$fullname;
> which undef's the source subroutine, one should use
> *{$fullname}=sub {};
ah, good trick! this also solves the problem for aliased
arrays/hashes/scalars
> This fix is obvious because that i
I found that a modified version of scrub_package
(written by Mark-Jason Dominus and described in perlfaq7)
works correctly and more efficiently than
Apache::PerlRun->flush_namespace
Here is the original scrub_package subroutine:
sub scrub_package {
no strict 'refs';
Unfortunately, the crucial part about clearing/removing
subroutine alias does not work when using
Apache::PerlRun->flush_namespace('Q')
I suspect this is a bug in PerlRun. Here is the demo program
(It can be run from the command line)
$ cat tmp.pl
#!/usr/bin/perl -w
use strict;
use Apache
On Mon, 1 May 2000, Richard Chen wrote:
> Hello,
> I am having a problem clearing variables and aliases
> in a temporary package name space. The source of the problem
> is in making legend cgi scripts work under Apache::Registry.
> But the problem can be isolated and shown by the following
Hello,
I am having a problem clearing variables and aliases
in a temporary package name space. The source of the problem
is in making legend cgi scripts work under Apache::Registry.
But the problem can be isolated and shown by the following
demo program:
$ cat foo.cgi
#!/usr/bin/perl -w
u