]> scm.dxcluster.org Git - spider.git/commitdiff
sorted abort
authorminima <minima>
Fri, 2 Mar 2001 22:32:46 +0000 (22:32 +0000)
committerminima <minima>
Fri, 2 Mar 2001 22:32:46 +0000 (22:32 +0000)
perl/ExtMsg.pm

index 60566f7ac27fe1f3f85b02945a5bf5c94dbb3cbb..33c17bfd44bcc18bef606c60a221453989da6259 100644 (file)
@@ -31,6 +31,11 @@ sub enqueue
        unless ($msg =~ /^[ABZ]/) {
                if ($msg =~ /^E[-\w]+\|([01])/) {
                        $conn->{echo} = $1;
        unless ($msg =~ /^[ABZ]/) {
                if ($msg =~ /^E[-\w]+\|([01])/) {
                        $conn->{echo} = $1;
+                       if ($1) {
+                               $conn->send_raw("\xFF\xFC\x01");
+                       } else {
+                               $conn->send_raw("\xFF\xFB\x01");
+                       }
                } else {
                        $msg =~ s/^[-\w]+\|//;
                        push (@{$conn->{outqueue}}, $msg . $conn->{lineend});
                } else {
                        $msg =~ s/^[-\w]+\|//;
                        push (@{$conn->{outqueue}}, $msg . $conn->{lineend});
@@ -76,7 +81,7 @@ sub dequeue
                } elsif ($conn->{state} eq 'WC') {
                        if (exists $conn->{cmd} && @{$conn->{cmd}}) {
                                $conn->_docmd($msg);
                } elsif ($conn->{state} eq 'WC') {
                        if (exists $conn->{cmd} && @{$conn->{cmd}}) {
                                $conn->_docmd($msg);
-                               unless ($conn->{state} eq 'WC' && @{$conn->{cmd}}) {
+                               if ($conn->{state} eq 'WC' && exists $conn->{cmd} &&  @{$conn->{cmd}} == 0) {
                                        $conn->{state} = 'C';
                                        &{$conn->{rproc}}($conn, "O$conn->{call}|telnet");
                                        delete $conn->{cmd};
                                        $conn->{state} = 'C';
                                        &{$conn->{rproc}}($conn, "O$conn->{call}|telnet");
                                        delete $conn->{cmd};
@@ -87,7 +92,7 @@ sub dequeue
        }
        if ($conn->{msg} && $conn->{state} eq 'WC' && exists $conn->{cmd} && @{$conn->{cmd}}) {
                $conn->_docmd($conn->{msg});
        }
        if ($conn->{msg} && $conn->{state} eq 'WC' && exists $conn->{cmd} && @{$conn->{cmd}}) {
                $conn->_docmd($conn->{msg});
-               unless ($conn->{state} eq 'WC' && @{$conn->{cmd}}) {
+               if ($conn->{state} eq 'WC' && exists $conn->{cmd} && @{$conn->{cmd}} == 0) {
                        $conn->{state} = 'C';
                        &{$conn->{rproc}}($conn, "O$conn->{call}|telnet");
                        delete $conn->{cmd};
                        $conn->{state} = 'C';
                        &{$conn->{rproc}}($conn, "O$conn->{call}|telnet");
                        delete $conn->{cmd};
@@ -111,6 +116,7 @@ sub new_client {
                $conn->{state} = 'WL';
 #              $conn->send_raw("\xff\xfe\x01\xff\xfc\x01\ff\fd\x22");
 #              $conn->send_raw("\xff\xfa\x22\x01\x01\xff\xf0");
                $conn->{state} = 'WL';
 #              $conn->send_raw("\xff\xfe\x01\xff\xfc\x01\ff\fd\x22");
 #              $conn->send_raw("\xff\xfa\x22\x01\x01\xff\xf0");
+               $conn->send_raw("\xFF\xFC\x01");
                _send_file($conn, "$main::data/issue");
                $conn->send_raw("Login: ");
     } else { 
                _send_file($conn, "$main::data/issue");
                $conn->send_raw("Login: ");
     } else {