Replace sleep calls for 'wake up'.
[unix-history] / usr / src / usr.bin / tip / aculib / dn11.c
index 8f7dcc7..091ff51 100644 (file)
@@ -1,17 +1,13 @@
-/*     dn11.c  4.11    81/11/29        */
+#ifndef lint
+static char sccsid[] = "@(#)dn11.c     4.14 (Berkeley) %G%";
+#endif
 
 
-#if DN11
 /*
  * Routines for dialing up on DN-11
  */
 #include "tip.h"
 /*
  * Routines for dialing up on DN-11
  */
 #include "tip.h"
-#include <setjmp.h>
-#include <errno.h>
-
-int dn_abort();
-
-int alarmtr();
 
 
+int dn_abort(), alarmtr();
 static jmp_buf jmpbuf;
 static int child = -1, dn;
 
 static jmp_buf jmpbuf;
 static int child = -1, dn;
 
@@ -80,6 +76,7 @@ dn_dialer(num, acu)
 
 alarmtr()
 {
 
 alarmtr()
 {
+
        alarm(0);
        longjmp(jmpbuf, 1);
 }
        alarm(0);
        longjmp(jmpbuf, 1);
 }
@@ -90,25 +87,22 @@ alarmtr()
  */
 dn_disconnect()
 {
  */
 dn_disconnect()
 {
+
        sleep(2);
        sleep(2);
-#ifdef VMUNIX
        if (FD > 0)
                ioctl(FD, TIOCCDTR, 0);
        if (FD > 0)
                ioctl(FD, TIOCCDTR, 0);
-#endif
        close(FD);
 }
 
 dn_abort()
 {
        close(FD);
 }
 
 dn_abort()
 {
+
        sleep(2);
        if (child > 0)
                kill(child, SIGKILL);
        if (dn > 0)
                close(dn);
        sleep(2);
        if (child > 0)
                kill(child, SIGKILL);
        if (dn > 0)
                close(dn);
-#ifdef VMUNIX
        if (FD > 0)
                ioctl(FD, TIOCCDTR, 0);
        if (FD > 0)
                ioctl(FD, TIOCCDTR, 0);
-#endif
        close(FD);
 }
        close(FD);
 }
-#endif