forked from Mirrors/freeswitch
ebfc333dc6
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@617 d0543943-73ff-0310-b7d9-9358b9ac24b2
16 lines
286 B
Perl
Executable File
16 lines
286 B
Perl
Executable File
#!/usr/local/bin/perl
|
|
use IO::Socket::INET;
|
|
|
|
my ($ip, $port, $file) = @ARGV;
|
|
|
|
$ip and $port or die "Usage $0: <ip> <port>\n";
|
|
|
|
$socket = new IO::Socket::INET->new( PeerPort => $port,
|
|
Proto => 'udp',
|
|
PeerAddr => $ip);
|
|
|
|
my $buf = `cat $file`;
|
|
|
|
$socket->send("$buf\n");
|
|
|