> I am having trouble using the Net::RawIP::dump function.
> 
> I keep getting the error Bad filehandle for line 4 in this code.
> What is wrong with $fh?
> 
> $p = open_offline($filename);
> $fh = dump_open($p, "file");
> $packet = next($p, \%hdr);
> dump($fh, \%hdr, $packet);

Can you post the rest of your code? I looked at the docs for this module on
CPAN which did not help  much. in fact i could barely get anything about the
dump method other than that is excepts a pointer to a file handle which i
assume dump_open takes care of. 
have you tried using the loop function instead of dump? 
also test the return value of dump_open to make sure you are getting a valid
file handle pointer. try a die statement there or use the ref function 
unless (ref($fh) eq "GLOB") { print "not a fh ref\n" }
 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to