I realize the syntax may not be correct as I rarely code perl for Windows, but the logic should be sound. Also, I'm guessing you have a limited number of unix os to deal with. A cleaner regex for the unix part is up to you.if ($^O =~ /WIN32/) { Net::Ping->new("icmp"); etcetera } elsif ($^O =~ /(irix | linux | SunOS | yougettheidea) /) { Net::Ping->new("tcp", 2); etcetera }
-Logan
"What do I want? I'm an American. I want more."
In reply to Sloppy, but simple
by logan
in thread net::ping not working for windows hosts
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |