fix who
[spider.git] / perl / ExtMsg.pm
index ee2ad231e40dfb8d3b935d62dfcc72fa197e348d..01a30924393e088535a9d2f98f97cff11004b5b7 100644 (file)
@@ -247,7 +247,7 @@ sub _dochat
        my $conn = shift;
        my $cmd = shift;
        my $line = shift;
-       
+               
        if ($line) {
                my ($expect, $send) = $cmd =~ /^\s*\'(.*)\'\s+\'(.*)\'/;
                if ($expect) {
@@ -261,6 +261,7 @@ sub _dochat
                        if ($line =~ /$expect/i) {
                                dbg('connect', "got: \"$expect\" sending: \"$send\"");
                                $conn->send_later($send);
+                               delete $conn->{msg}; # get rid any input if a match
                                return;
                        }
                }