Chris_LSU has asked for the wisdom of the Perl Monks concerning the following question:
my $binip = pack "c4", ($a, $b, $c, $d);
The previous line is this:
my ($a, $b, $c, $d) = split(/\./, $src_ip);
Which is the first line of a foreach loop:
foreach $src_ip (sort by_ip keys(%tgt_sys))
The script is set to dump STDERR to a log file. When this script runs, it seems to run fine, then the log fills up with this message:
Character in "c" format wrapped at /usr/local/shadow/SHADOW-1.8/find_scan.pl line 142, <STDIN> line 5507847.
Line 142 is where the first piece I posted; the line with the pack function in it. I did some checking into the pack function, but what I've learned so far about it doesn't seem to explain what is causing this message to be generated, and honestly, I'm not even sure exactly what it means. I figured out that line 5507847 is the last line of the file that is being streamed into the script, so I'm guessing that for some reason the 'pack' line isn't "handling" it correctly. My supervisor suggested it may be the presence of a newline, so I tried a chomp. But it didn't work; either I put it in the wrong place, or it wasn't the newline.
I need some help.
20040904 Edit by castaway: Changed title from ''pack' errors'
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: pack() gives me "character wrapped" warnings
by BrowserUk (Patriarch) on Sep 03, 2004 at 21:18 UTC | |
|
Re: pack() gives me "character wrapped" warnings
by saintmike (Vicar) on Sep 03, 2004 at 21:06 UTC | |
|
Re: pack() gives me "character wrapped" warnings
by Aristotle (Chancellor) on Sep 03, 2004 at 23:04 UTC | |
|
Re: pack() gives me "character wrapped" warnings in more than two year old software?
by shenme (Priest) on Sep 04, 2004 at 01:59 UTC | |
by Chris_LSU (Sexton) on Sep 07, 2004 at 15:07 UTC | |
|
Re: pack() gives me "character wrapped" warnings
by bart (Canon) on Sep 04, 2004 at 08:46 UTC |