use IO::File;
use IO::Socket;
use IPC::Open2;
-use Carp qw{cluck};
# cease communications
sub cease
{
my $sendz = shift;
if ($conn && $sendz) {
- $conn->send_now("Z$call|bye...\n");
+ $conn->send_now("Z$call|bye...");
sleep(1);
}
$stdout->flush if $stdout;
$buffered = $line; # set buffered or unbuffered
} elsif ($sort eq 'Z') { # end, disconnect, go, away .....
cease(0);
- }
+ }
+
+ # ******************************************************
+ # ******************************************************
+ # any other sorts that might happen are silently ignored.
+ # ******************************************************
+ # ******************************************************
}
$lasttime = time;
}
doconnect($1, $2) if /^\s*co\w*\s+(\w+)\s+(.*)$/io;
doabort($1) if /^\s*a\w*\s+(.*)/io;
dotimeout($1) if /^\s*t\w*\s+(\d+)/io;
- dochat($1, $2) if /\s*\'(.*)\'\s+\'(.*)\'/io;
- if (/\s*cl\w+\s+(.*)/io) {
+ dochat($1, $2) if /^\s*\'(.*)\'\s+\'(.*)\'/io;
+ if (/^\s*cl\w+\s+(.*)/io) {
doclient($1);
last;
}