mjmjmj has asked for the wisdom of the Perl Monks concerning the following question:
i have a perl source code that work
now i whant add LocalPort to this code taht specify the source port what i must to do? i change that to this but get erorrmy $host=$_[0]; my $sock = new IO::Socket::INET(PeerAddr=>$host,PeerPort=>'27015',Prot +o=>'udp'); die "Could not create socket: $!\n" unless $sock;
my $host=$_[0]; my $sock = new IO::Socket::INET(PeerAddr=>$host,PeerPort=>'27015',Prot +o=>'udp',LocalPort=>'27005'); die "Could not create socket: $!\n" unless $sock;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Socket Problem
by ahmad (Hermit) on Mar 26, 2006 at 21:19 UTC | |
|
Re: Socket Problem
by mikeock (Hermit) on Mar 26, 2006 at 19:23 UTC |