dru145 has asked for the wisdom of the Perl Monks concerning the following question:
my $ip = qr/\b192.168.3.5\b/; my $line = 0; my @fwlog; my $logfile = "/tmp/05jul01.drop"; open LOG, "$logfile" or die "Can't open $logfile: $!\n"; while ($line=<LOG>){ chomp($line); while($line =~ $ip) { print "$line\n"; #push (@fwlog,$line); } } close LOG; #print "@fwlog\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Saving Results of a while loop
by arturo (Vicar) on Aug 01, 2001 at 18:44 UTC | |
|
Re: Saving Results of a while loop
by tachyon (Chancellor) on Aug 01, 2001 at 19:15 UTC | |
|
Re: Saving Results of a while loop
by VSarkiss (Monsignor) on Aug 01, 2001 at 18:42 UTC | |
by tadman (Prior) on Aug 01, 2001 at 18:49 UTC | |
by Hofmator (Curate) on Aug 01, 2001 at 20:02 UTC | |
by tadman (Prior) on Aug 01, 2001 at 20:10 UTC | |
|
(ichimunki) Re: Saving Results of a while loop
by ichimunki (Priest) on Aug 01, 2001 at 18:48 UTC | |
|
Re: Saving Results of a while loop
by rob_au (Abbot) on Aug 01, 2001 at 18:37 UTC |