in reply to Re^4: Data::Dumper is returning empty
in thread Data::Dumper is returning empty

Using the following code gives a different error about scoping

Global symbol "%nic" requires explicit package name

for my $nic (networkInfo()) { print "Device: $nic{device} has IP Address $nic{ip}\n" . "\tMask: $nic{mask}\n" . "\tBroadcast: $nic{bcast}\n"; print "Device: $nic{device} also IPv6 address $nic{ip6}\n" if defined($nic->{device}); }

Replies are listed 'Best First'.
Re^6: Data::Dumper is returning empty
by ikegami (Patriarch) on Jan 19, 2010 at 19:49 UTC
    Copy and paste error on my part. The hash is accessed via the ref in $nic, so $nic needs to be derefed. Fixed in grandparent.

      what does fixed in grandparent mean?