make sure nothing can be sent to AGW after error
[spider.git] / perl / AGWMsg.pm
index c167d994a883eb7d0433495b512d03582679060d..4d1068ff35707ca813b03d5ad2dbf86d7da07705 100644 (file)
@@ -125,6 +125,8 @@ sub _sendf
        my $pid  = shift || 0;
        my $data = shift || '';
        my $len  = 0;
+
+       return unless $sock;
        
        $len = length $data; 
        if ($sort eq 'y' || $sort eq 'H') {