P is for Practical | |
PerlMonks |
Re^3: Undefined Subroutine & Global symbol requires explicit package nameby lune (Pilgrim) |
on Jan 24, 2012 at 18:31 UTC ( [id://949741]=note: print w/replies, xml ) | Need Help?? |
You didn't really understand the first answer you got on the issue: "where did you find inet_aton documented?".
When you call a subroutine, it must be defined somewhere, unless it is a builtin Perl function, like "each" and "print" in your example. In your code, you want to use functions from the module "Socket.pm" - so you have to "use Socket" to make these functions available. You can tell that inet_aton is not a Perl function simply by checking with man perlfunc or by trying Of course, if you misspell a function you'll get the same error, but this is not the issue here. further documentation
In Section
Seekers of Perl Wisdom
|
|