home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume5 / kermit.hdb < prev    next >
Internet Message Format  |  1989-02-03  |  19KB

  1. Path: xanth!nic.MR.NET!hal!ncoast!allbery
  2. From: eric@snark.UUCP (Eric S. Raymond)
  3. Newsgroups: comp.sources.misc
  4. Subject: v05i055: Kermit patches to enable dial to use HDB database, like cu
  5. Message-ID: <8811200118.AA00922@snark.UUCP>
  6. Date: 22 Nov 88 03:25:44 GMT
  7. Sender: allbery@ncoast.UUCP
  8. Reply-To: eric@snark.UUCP (Eric S. Raymond)
  9. Lines: 603
  10. Approved: allbery@ncoast.UUCP
  11.  
  12. Posting-number: Volume 5, Issue 55
  13. Submitted-by: "Eric S. Raymond" <eric@snark.UUCP>
  14. Archive-name: kermit.hdb
  15.  
  16. [About gets():  anyone who'd use gets() with a *pointer* is begging for a
  17. fingerd botch; at least my patch would make it obvious a lot sooner.  I do
  18. concede that the trailing newline is something of a problem, though.  ++bsa]
  19.  
  20. This article is a patch set for the 4D release of C-Kermit.  The code changes
  21. fix some minor compilation glitches under SVr2 UNIX, but more importantly they
  22. enable the ckermit dial command to accept a system name agument (like cu) and
  23. use the information represented in the Basic Networking Utilities (HoneyDanBer
  24. UUCP) database to set line, speed and modem type for the dial out.
  25.  
  26. For this to work, the software must be compiled with -DSVR2 on. This can be
  27. accomplished via 'make hdbx'. See the patch to ckuker.doc (first in the set)
  28. for details.
  29.  
  30. These patches work, but they're a bit on the crude side (Dialcodes ought to
  31. be supported, and the code could be taught how to interpret the Dialers file).
  32. I hope the Kermit maintainers (wherever they are) will pick these up, polish
  33. them a bit and include them in the next release.
  34.  
  35. If you are a Kermit maintainer, please ACK by email -- it would be nice to know
  36. this posting hasn't just dropped into a void.
  37.  
  38. *** ckuker.doc-old    Sun Nov 20 00:37:52 1988
  39. --- ckuker.doc    Sun Nov 20 00:46:21 1988
  40. ***************
  41. *** 1284,1289 ****
  42. --- 1284,1297 ----
  43.   The device used for dialing out is the one selected in  the  most  recent  "set
  44.   line"  command  (or on a workstation, the default line if no "set line" command
  45.   was given).  The "dial" command calls locks the path (see the section  on  line
  46. + One special convenience feature is available in the dial command under SVR2 and
  47. + later UNIX systems using HoneyDanBer UUCP. If you give dial a system name
  48. + argument that it can find in the Systems file, it will search through the
  49. + Systems and Devices file and set the line, modem type and communication speed
  50. + in accordance with what it finds there. However, dial codes will *not* be
  51. + interpreted. Nor will the HDB modemcap be used; for now, the modem name in the
  52. + Devices file must match one of kermit's internally-supported types.
  53.   
  54.   
  55.   
  56. *** ckuker.mak-old    Thu Nov 17 16:32:09 1988
  57. --- ckuker.mak    Thu Nov 17 18:34:45 1988
  58. ***************
  59. *** 9,14 ****
  60. --- 9,15 ----
  61.   # for Berkeley Unix 2.9 (PDP-11), "make bsd29"
  62.   # for DEC Ultrix 1.1 or 1.2, "make bsd"
  63.   # for AT&T 3Bx systems, "make att3bx"
  64. + # for AT&T System V with HoneyDanBer UUCP, "make hdbx"
  65.   # for AT&T generic System III/System V, "make sys3" or "make sys3nid"
  66.   # for Bell Unix Version 7 (aka 7th Edition), "make v7" (but see below)
  67.   # for Microsoft Xenix (/286, PC/AT, etc), "make xenix"
  68. ***************
  69. *** 138,147 ****
  70.       @echo 'Make what?  You must tell which system to make C-Kermit for.'
  71.   
  72.   wermit: ckcmai.o ckucmd.o ckuusr.o ckuus2.o ckuus3.o ckcpro.o ckcfns.o \
  73. !          ckcfn2.o ckucon.o ckutio.o ckufio.o ckudia.o ckuscr.o
  74.       $(CC2) $(LNKFLAGS) -o wermit ckcmai.o ckutio.o ckufio.o ckcfns.o \
  75.            ckcfn2.o ckcpro.o ckucmd.o ckuus2.o ckuus3.o ckuusr.o \
  76. !          ckucon.o ckudia.o ckuscr.o
  77.   
  78.   ckcmai.o: ckcmai.c ckcker.h ckcdeb.h
  79.   
  80. --- 139,148 ----
  81.       @echo 'Make what?  You must tell which system to make C-Kermit for.'
  82.   
  83.   wermit: ckcmai.o ckucmd.o ckuusr.o ckuus2.o ckuus3.o ckcpro.o ckcfns.o \
  84. !          ckcfn2.o ckucon.o ckutio.o ckufio.o ckudia.o ckuscr.o ckubnu.o
  85.       $(CC2) $(LNKFLAGS) -o wermit ckcmai.o ckutio.o ckufio.o ckcfns.o \
  86.            ckcfn2.o ckcpro.o ckucmd.o ckuus2.o ckuus3.o ckuusr.o \
  87. !          ckucon.o ckudia.o ckuscr.o ckubnu.o
  88.   
  89.   ckcmai.o: ckcmai.c ckcker.h ckcdeb.h
  90.   
  91. ***************
  92. *** 175,181 ****
  93.   
  94.   ckudia.o: ckudia.c ckcker.h ckcdeb.h
  95.   
  96. ! ckuscr.o: ckuscr.c ckcker.h ckcdeb.h
  97.   #
  98.   ###########################################################################
  99.   #
  100. --- 176,184 ----
  101.   
  102.   ckudia.o: ckudia.c ckcker.h ckcdeb.h
  103.   
  104. ! ckuscr.o: ckuscr.c ckucmd.h ckcker.h ckcdeb.h
  105. ! ckubnu.o: ckubnu.c ckcker.h ckcdeb.h
  106.   #
  107.   ###########################################################################
  108.   #
  109. ***************
  110. *** 208,222 ****
  111.       make wermit "CFLAGS = -DUXIII -DDEBUG -DTLOG -i -O" "LNKFLAGS = -i"
  112.   
  113.   
  114.   #Generic ATT System III or System V (no I&D space)
  115.   sys3nid:
  116.       make wermit "CFLAGS = -DUXIII -DDEBUG -DTLOG -O" "LNKFLAGS ="
  117.   
  118.   
  119.   #AT&T 3B-series computers running System V
  120. ! #  Only difference from sys3 is lock file stuff...
  121.   att3bx:
  122. !     make wermit "CFLAGS = -DUXIII -DATT3BX -DDEBUG -DTLOG -i -O" \
  123.           "LNKFLAGS = -i"
  124.   
  125.   
  126. --- 211,230 ----
  127.       make wermit "CFLAGS = -DUXIII -DDEBUG -DTLOG -i -O" "LNKFLAGS = -i"
  128.   
  129.   
  130. + #Generic ATT System V with HoneyDanBer
  131. + hdbx:
  132. +     make "CFLAGS = -DUXIII -DDEBUG -DTLOG -DSVR2 -O" "LNKFLAGS =" wermit
  133.   #Generic ATT System III or System V (no I&D space)
  134.   sys3nid:
  135.       make wermit "CFLAGS = -DUXIII -DDEBUG -DTLOG -O" "LNKFLAGS ="
  136.   
  137.   
  138.   #AT&T 3B-series computers running System V
  139. ! #  Only difference from sys3 is lock file stuff & SVR2 support...
  140.   att3bx:
  141. !     make wermit "CFLAGS = -DUXIII -DATT3BX -DDEBUG -DTLOG -DSVR2 -i -O" \
  142.           "LNKFLAGS = -i"
  143.   
  144.   
  145. ***************
  146. *** 281,283 ****
  147. --- 289,298 ----
  148.   #Mostly Berkeley-like, but with some ATTisms
  149.   c70:
  150.       make wermit "CFLAGS= -DBSD4 -DC70 -DDEBUG -DTLOG"
  151. *** ckcdeb.h-old    Thu Nov 17 11:09:19 1988
  152. --- ckcdeb.h    Thu Nov 17 17:10:27 1988
  153. ***************
  154. *** 102,113 ****
  155.   
  156.   
  157.   /* Some special includes for VAX/VMS */
  158.   #ifdef vax11c
  159.   #include ssdef
  160.   #include stsdef
  161.   #endif
  162.   /* Program return codes for VMS, DECUS C, and Unix */
  163.   
  164.   #ifdef vax11c
  165. --- 102,113 ----
  166.   
  167.   
  168.   /* Some special includes for VAX/VMS */
  169. ! /*
  170.   #ifdef vax11c
  171.   #include ssdef
  172.   #include stsdef
  173.   #endif
  174. ! */
  175.   /* Program return codes for VMS, DECUS C, and Unix */
  176.   
  177.   #ifdef vax11c
  178. *** ckcfn2.c-old    Thu Nov 17 18:00:53 1988
  179. --- ckcfn2.c    Thu Nov 17 18:02:48 1988
  180. ***************
  181. *** 298,304 ****
  182.         if (t == 3) cccount++;        /* Count any control-C's */
  183.   
  184.       if (t == eol) return('Q');
  185. !     *l = unchar(t);            /* Packet length */
  186.       debug(F101," pkt len","",*l);
  187.       if (*l + i + 2 > RBUFL) {     /* Sticks out too far? */
  188.           debug(F101," ** overrun","",i);
  189. --- 298,304 ----
  190.         if (t == 3) cccount++;        /* Count any control-C's */
  191.   
  192.       if (t == eol) return('Q');
  193. !     *l = todigit(t);            /* Packet length */
  194.       debug(F101," pkt len","",*l);
  195.       if (*l + i + 2 > RBUFL) {     /* Sticks out too far? */
  196.           debug(F101," ** overrun","",i);
  197. ***************
  198. *** 310,316 ****
  199.       if ((t = recpkt[i++]) == stchr) continue;
  200.       if (cccount && (t == 3)) { conoll("^C^C exit..."); doexit(0); }
  201.       if (t == eol) return('Q');
  202. !     *n = unchar(t);
  203.       debug(F101,"rpack: n","",*n);
  204.   
  205.   /* cont'd... */
  206. --- 310,316 ----
  207.       if ((t = recpkt[i++]) == stchr) continue;
  208.       if (cccount && (t == 3)) { conoll("^C^C exit..."); doexit(0); }
  209.       if (t == eol) return('Q');
  210. !     *n = todigit(t);
  211.       debug(F101,"rpack: n","",*n);
  212.   
  213.   /* cont'd... */
  214. *** ckcfns.c-old    Thu Nov 17 18:01:08 1988
  215. --- ckcfns.c    Thu Nov 17 18:02:41 1988
  216. ***************
  217. *** 139,145 ****
  218.       while ((a = *buf++) != '\0') {
  219.       if (rptflg) {            /* Repeat processing? */
  220.           if (a == rptq) {        /* Yes, got a repeat prefix? */
  221. !         rpt = unchar(*buf++);    /* Yes, get the repeat count, */
  222.           a = *buf++;        /* and get the prefixed character. */
  223.           }
  224.       }
  225. --- 139,145 ----
  226.       while ((a = *buf++) != '\0') {
  227.       if (rptflg) {            /* Repeat processing? */
  228.           if (a == rptq) {        /* Yes, got a repeat prefix? */
  229. !         rpt = todigit(*buf++);    /* Yes, get the repeat count, */
  230.           a = *buf++;        /* and get the prefixed character. */
  231.           }
  232.       }
  233. ***************
  234. *** 640,660 ****
  235.   
  236.       len = strlen(data);                /* Number of fields */
  237.   
  238. !     x = (len-- > 0) ? unchar(data[0]) : DSPSIZ;            /* Packet size */
  239.       if (spsizf == 0)
  240.       spsiz = (x < 10) ? DSPSIZ : x;
  241.   
  242. !     x = (len-- > 0) ? unchar(data[1]) : DMYTIM;        /* Timeout */
  243.       if (timef == 0)
  244.       timint = (x < 0) ? DMYTIM : x;
  245.   
  246.       npad = 0; padch = '\0';                        /* Padding */
  247.       if (len-- > 0) {
  248. !     npad = unchar(data[2]);
  249.       if (len-- > 0) padch = ctl(data[3]); else padch = 0;
  250.       }
  251.   
  252. !     seol = (len-- > 0) ? unchar(data[4]) : '\r';    /* Terminator  */
  253.       if ((seol < 2) || (seol > 037)) seol = '\r';
  254.   
  255.       ctlq = (len-- > 0) ? data[5] : CTLQ;                /* Control prefix */
  256. --- 640,660 ----
  257.   
  258.       len = strlen(data);                /* Number of fields */
  259.   
  260. !     x = (len-- > 0) ? todigit(data[0]) : DSPSIZ;            /* Packet size */
  261.       if (spsizf == 0)
  262.       spsiz = (x < 10) ? DSPSIZ : x;
  263.   
  264. !     x = (len-- > 0) ? todigit(data[1]) : DMYTIM;        /* Timeout */
  265.       if (timef == 0)
  266.       timint = (x < 0) ? DMYTIM : x;
  267.   
  268.       npad = 0; padch = '\0';                        /* Padding */
  269.       if (len-- > 0) {
  270. !     npad = todigit(data[2]);
  271.       if (len-- > 0) padch = ctl(data[3]); else padch = 0;
  272.       }
  273.   
  274. !     seol = (len-- > 0) ? todigit(data[4]) : '\r';    /* Terminator  */
  275.       if ((seol < 2) || (seol > 037)) seol = '\r';
  276.   
  277.       ctlq = (len-- > 0) ? data[5] : CTLQ;                /* Control prefix */
  278. ***************
  279. *** 905,911 ****
  280.   */
  281.   
  282.   cwd(vdir) char *vdir; {
  283. !     vdir[unchar(*vdir) + 1] = '\0';    /* End with a null */
  284.       if (zchdir(vdir+1)) {
  285.       encstr(vdir+1);
  286.       ack1(data);
  287. --- 905,911 ----
  288.   */
  289.   
  290.   cwd(vdir) char *vdir; {
  291. !     vdir[todigit(*vdir) + 1] = '\0';    /* End with a null */
  292.       if (zchdir(vdir+1)) {
  293.       encstr(vdir+1);
  294.       ack1(data);
  295. *** ckcker.h-old    Thu Nov 17 17:50:01 1988
  296. --- ckcker.h    Thu Nov 17 17:53:16 1988
  297. ***************
  298. *** 84,89 ****
  299.   /* Macros */
  300.   
  301.   #define tochar(ch)  ((ch) + SP )    /* Number to character */
  302. ! #define unchar(ch)  ((ch) - SP )    /* Character to number */
  303.   #define ctl(ch)     ((ch) ^ 64 )    /* Controllify/Uncontrollify */
  304.   #define unpar(ch)   ((ch) & 127)    /* Clear parity bit */
  305. --- 84,89 ----
  306.   /* Macros */
  307.   
  308.   #define tochar(ch)  ((ch) + SP )    /* Number to character */
  309. ! #define todigit(ch)  ((ch) - SP )    /* Character to number */
  310.   #define ctl(ch)     ((ch) ^ 64 )    /* Controllify/Uncontrollify */
  311.   #define unpar(ch)   ((ch) & 127)    /* Clear parity bit */
  312. *** ckcpro.w-old    Sun Nov 20 00:17:08 1988
  313. --- ckcpro.w    Sun Nov 20 00:17:56 1988
  314. ***************
  315. *** 113,119 ****
  316.                else { errpkt("Can't type file"); SERVE; } }
  317.   
  318.   <generic>U { x = *(srvcmd+1);            /* Disk Usage query */
  319. !              x = ((x == '\0') || (x == unchar(0)));
  320.            x = (x ? syscmd(SPACMD,"") : syscmd(SPACM2,srvcmd+2));
  321.                if (x) BEGIN ssinit; else { errpkt("Can't check space"); SERVE; }}
  322.   
  323. --- 113,119 ----
  324.                else { errpkt("Can't type file"); SERVE; } }
  325.   
  326.   <generic>U { x = *(srvcmd+1);            /* Disk Usage query */
  327. !              x = ((x == '\0') || (x == todigit(0)));
  328.            x = (x ? syscmd(SPACMD,"") : syscmd(SPACM2,srvcmd+2));
  329.                if (x) BEGIN ssinit; else { errpkt("Can't check space"); SERVE; }}
  330.   
  331. *** ckubnu.c-old    Sun Nov 20 00:46:58 1988
  332. --- ckubnu.c    Sat Nov 19 23:43:02 1988
  333. ***************
  334. *** 0 ****
  335. --- 1,153 ----
  336. + /*
  337. +  * ckubnu.c -- set call parameters from the SVR2 database files
  338. +  *
  339. +  * A quick hack to make the dial command more convenient on systems with the
  340. +  * HoneyDanBer UUCP database files available, by Eric S. Raymond (eric@snark).
  341. +  * This code is released to the public domain, do with it what ye will.
  342. +  *
  343. +  * Theory: call bnuset() on the argument of a dial command before doing
  344. +  * anything else. If the dial argument matches a system name in the UUCP
  345. +  * database, the code will try to set speed, line, and modem-type properly;
  346. +  * and bnuset() will modify its argument into the telephone number of the
  347. +  * calling system.
  348. +  *
  349. +  * Implementation: mine all the stuff out of the Systems and Devices files,
  350. +  * then write corresponding kermit commands to a disappearing take-file. This
  351. +  * way we get all of kermit's normal command checking and debug options for
  352. +  * free.
  353. +  *
  354. +  * Bugs: we don't interpret dialcodes. Nor do we use the Dialers file, which
  355. +  * would make us independent of the hardwired modem-type cruft in ckudia.c.
  356. +  * Like I said, this is a quick hack.
  357. +  */
  358. + #ifdef SVR2
  359. + #include "ckcdeb.h"
  360. + #include "ckcker.h"
  361. + #include "ckuusr.h"
  362. + #include <stdio.h>
  363. + #include <ctype.h>
  364. + #include <string.h>
  365. + #define SYSTEMS    "/usr/lib/uucp/Systems"
  366. + #define DEVICES    "/usr/lib/uucp/Devices"
  367. + #define WSPC    "\t\n "
  368. + static char *
  369. + findline(key, qual, file)
  370. + /* find a line in the given file beginning with the given word, if any */
  371. + char    *key;
  372. + char    *qual;
  373. + char    *file;
  374. + {
  375. +     char    buf[BUFSIZ], *cp;
  376. +     FILE    *fp;
  377. +     if ((fp = fopen(file, "r")) != (FILE *)NULL)
  378. +         while (fgets(buf, BUFSIZ, fp) != (char *)NULL)
  379. +         {
  380. +         char    *sys;
  381. +         int    foundqual = (qual == (char *)NULL);
  382. +         /* skip comments */
  383. +         if (cp = strchr(buf, '#'))
  384. +             *cp = '\0';
  385. +         /* check that qual is present somewhere on the line */
  386. +         if (!foundqual)
  387. +             for (cp = buf; *cp; cp++)
  388. +             if (*cp == *qual && !strncmp(cp, qual, strlen(qual)))
  389. +             {
  390. +                 foundqual = 1;
  391. +                 break;
  392. +             }
  393. +         /* if it is and the first token matches sys, jackpot! */
  394. +         sys = strtok(buf, "\t ");
  395. +         if (foundqual && (sys != (char *)NULL) && !strcmp(sys, key))
  396. +             return(buf);
  397. +         }
  398. +     return((char *)NULL);
  399. + }
  400. + bnuset(telnbr)
  401. + char *telnbr;
  402. + {
  403. +     char    *sysentry, *device, *cp, speedtok[BUFSIZ], devtok[BUFSIZ];
  404. +     int        nspeed;
  405. +     if (!isdigit(telnbr[0])
  406. +         && (sysentry = findline(telnbr, (char *)NULL, SYSTEMS)))
  407. +     {
  408. +         (void) strtok((char *)NULL, WSPC);    /* skip call time */
  409. +         if (device = strtok((char*)NULL, WSPC))
  410. +         {
  411. +         /* we'll deal with the device type below */
  412. +         (void) strcpy(devtok, device);
  413. +         /* look for the line speed field */
  414. +         if (cp = strtok((char*)NULL, WSPC))
  415. +         {
  416. +             /* set speed from this field */
  417. +             (void) strcpy(speedtok, cp);
  418. +             nspeed = atoi(cp);
  419. +             if (cp = strtok((char*)NULL, WSPC))
  420. +             {
  421. +             /*
  422. +              * Set phone number from this field.
  423. +              * Someday, do Dialcodes processing here.
  424. +              */
  425. +             (void) strcpy(telnbr, cp);
  426. +             /* feed the rest of the line to script, maybe? */
  427. +             }
  428. +         }
  429. +         /* O.K., look for a devtype/speed match in DEVICES */
  430. +         if ((device = findline(devtok,speedtok,DEVICES)) !=(char*)NULL)
  431. +         {
  432. +             /* look for the device field */
  433. +             if (cp = strtok((char*)NULL, WSPC))
  434. +             {
  435. +             extern char cmdbuf[], ttname[];
  436. +             extern int speed, local, mdmtyp;
  437. +             char fullname[BUFSIZ];
  438. +             int    x;
  439. +             /* it's field 2 */
  440. +             (void) sprintf(fullname, "/dev/%s", cp);
  441. +             if (ttopen(fullname,&x,mdmtyp) < 0 ) 
  442. +                 perror("Sorry, can't open line");
  443. +             else
  444. +             {
  445. +                 local = 1;
  446. +                 (void) strcpy(ttname,fullname);
  447. +                 debug(F111,"set line ",ttname,local);
  448. +                 /*
  449. +                  * Since we found a device, set speed too.
  450. +                  * We found it in Devices, so assume it's valid.
  451. +                  */
  452. +                 speed = nspeed;
  453. +             }
  454. +             /* skip field 3, don't know what it's good for */
  455. +             (void) strtok((char *)NULL, WSPC);
  456. +             /* skip field 4, it's just the speed qualifier */
  457. +             (void) strtok((char *)NULL, WSPC);
  458. +             /* now set the modem type from field 5 */
  459. +             if (cp = strtok((char *)NULL, WSPC))
  460. +             {
  461. +                 extern struct keytab mdmtab[];
  462. +                 extern int nmdm;
  463. +                 mdmtyp = lookup(mdmtab,cp,nmdm,&x);
  464. +             }
  465. +             }
  466. +         }
  467. +         }
  468. +     }
  469. + }
  470. + #endif /* SVR2 */
  471. *** ckucmd.h-old    Thu Nov 17 17:54:32 1988
  472. --- ckucmd.h    Thu Nov 17 17:58:38 1988
  473. ***************
  474. *** 9,14 ****
  475. --- 9,20 ----
  476.    copyright notice is retained.
  477.   */
  478.    
  479. + #ifdef SVR2
  480. + typedef void    catch_t;
  481. + #else
  482. + typedef int    catch_t;
  483. + #endif
  484.   /* Special getchars... */
  485.    
  486.   #ifdef vax11c
  487. *** ckudia.c-old    Thu Nov 17 11:33:43 1988
  488. --- ckudia.c    Sat Nov 19 21:50:38 1988
  489. ***************
  490. *** 441,448 ****
  491.   
  492.   static jmp_buf sjbuf;
  493.   
  494. ! static int (*savAlrm)();    /* for saving alarm handler */
  495. ! static int (*savInt)();        /* for saving interrupt handler */
  496.   
  497.   dialtime() {            /* timer interrupt handler */
  498.       longjmp( sjbuf, F_time );
  499. --- 441,448 ----
  500.   
  501.   static jmp_buf sjbuf;
  502.   
  503. ! static catch_t (*savAlrm)();    /* for saving alarm handler */
  504. ! static catch_t (*savInt)();    /* for saving interrupt handler */
  505.   
  506.   dialtime() {            /* timer interrupt handler */
  507.       longjmp( sjbuf, F_time );
  508. ***************
  509. *** 512,517 ****
  510. --- 512,521 ----
  511.       int n, n1;
  512.       char *pc;        /* pointer to a character */
  513.   
  514. + #ifdef SVR2
  515. +     bnuset(telnbr);    /* try to set parameters from the SVR2 files */
  516. + #endif /* SVR2 */
  517.       if (!mdmtyp) {
  518.           printf("Sorry, you must 'set modem' first\n");
  519.           return(-2);
  520. ***************
  521. *** 537,543 ****
  522.   
  523.                       /* interdigit waits for tone dial */
  524.   /* ...dial, cont'd */
  525.   
  526.       waitct = 1*strlen(telnbr) ;    /* compute time to dial worst case */
  527.       waitct += pmdminf->dial_time;    /* dialtone + completion wait times */
  528. --- 541,546 ----
  529. *** ckuscr.c-old    Thu Nov 17 11:09:45 1988
  530. --- ckuscr.c    Thu Nov 17 18:33:38 1988
  531. ***************
  532. *** 32,37 ****
  533. --- 32,38 ----
  534.   #include <signal.h>
  535.   #include <setjmp.h>
  536.   #include "ckcker.h"
  537. + #include "ckucmd.h"
  538.   
  539.   extern int local, speed, flow, seslog, mdmtyp;
  540.   extern char ttname[];
  541. ***************
  542. *** 217,223 ****
  543.   
  544.   login(cmdstr) char *cmdstr; {
  545.   
  546. !     int (*saveAlm)();    /* save incomming alarm function */
  547.       char *e;
  548.   
  549.       s = cmdstr;            /* make global to ckuscr.c */
  550. --- 218,224 ----
  551.   
  552.   login(cmdstr) char *cmdstr; {
  553.   
  554. !     catch_t (*saveAlm)();    /* save incoming alarm function */
  555.       char *e;
  556.   
  557.       s = cmdstr;            /* make global to ckuscr.c */
  558. *** ckuusr.c-old    Thu Nov 17 12:14:47 1988
  559. --- ckuusr.c    Thu Nov 17 20:51:16 1988
  560. ***************
  561. *** 1042,1048 ****
  562.       else {                /* Parent */
  563.    
  564.           int wstat;            /* Kermit must wait for child */
  565. !     int (*istat)(), (*qstat)();
  566.    
  567.       istat = signal(SIGINT,SIG_IGN);    /* Let the fork handle keyboard */
  568.       qstat = signal(SIGQUIT,SIG_IGN); /* interrupts itself... */
  569. --- 1042,1048 ----
  570.       else {                /* Parent */
  571.    
  572.           int wstat;            /* Kermit must wait for child */
  573. !     catch_t (*istat)(), (*qstat)();
  574.    
  575.       istat = signal(SIGINT,SIG_IGN);    /* Let the fork handle keyboard */
  576.       qstat = signal(SIGQUIT,SIG_IGN); /* interrupts itself... */
  577. -- 
  578.       Eric S. Raymond                     (the mad mastermind of TMN-Netnews)
  579.       Email: eric@snark.uu.net                       CompuServe: [72037,2306]
  580.       Post: 22 S. Warren Avenue, Malvern, PA 19355      Phone: (215)-296-5718
  581.