Mr. Shawn H. Corey wrote:
> On Sun, 2008-09-21 at 09:59 -0700, Ron Bergin wrote:
>>
>> > #!/usr/bin/perl
>> > #
>> You're missing 2 very important pragmas that should be in every script
>> you write.
>>
>> use warnings; #
>> use strict;   # forces you to declare your vars prior to their use.
>>
[snip]
>> my $ntop = 10;
>> my (%quad, %port);
>>
>
> my %quad = ();
> my %port = ();
>
> __END__
>
> You should always set your variables to a known value.  perl will clear
> them when it first starts, but other interpreters like mod_perl do not;
> they re-use the data space as-is for efficiency.  You could end up with
> data from the previous run.
>
>
> --
> Just my 0.00000002 million dollars worth,
>   Shawn
>
Hmmm, when did mod_perl become an interpreter in its own right like perl? 
Someone else with more knowledge than I can correct me if I'm wrong, but as
far as I know, mod_perl is a linking/binding of the perl interpreter with the
apache web server.

-- 
Ron Bergin



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to