projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
BSD 4_3_Tahoe release
[unix-history]
/
usr
/
src
/
usr.bin
/
tip
/
acu.c
diff --git
a/usr/src/usr.bin/tip/acu.c
b/usr/src/usr.bin/tip/acu.c
index
4e416e3
..
1cc74cc
100644
(file)
--- a/
usr/src/usr.bin/tip/acu.c
+++ b/
usr/src/usr.bin/tip/acu.c
@@
-1,6
+1,12
@@
+/*
+ * Copyright (c) 1983 Regents of the University of California.
+ * All rights reserved. The Berkeley software License Agreement
+ * specifies the terms and conditions for redistribution.
+ */
+
#ifndef lint
#ifndef lint
-static char sccsid[] = "@(#)acu.c
4.11 (Berkeley) %G%
";
-#endif
+static char sccsid[] = "@(#)acu.c
5.5 (Berkeley) 12/4/87
";
+#endif
not lint
#include "tip.h"
#include "tip.h"
@@
-35,7
+41,8
@@
connect()
if (!DU) { /* regular connect message */
if (CM != NOSTR)
if (!DU) { /* regular connect message */
if (CM != NOSTR)
- pwrite(FD, cp, size(CM));
+ pwrite(FD, CM, size(CM));
+ logent(value(HOST), "", DV, "call completed");
return (NOSTR);
}
/*
return (NOSTR);
}
/*
@@
-56,14
+63,13
@@
connect()
else
(*acu->acu_abort)();
}
else
(*acu->acu_abort)();
}
- delock(uucplock);
- exit(1);
+ return ("interrupt");
}
if ((acu = acutype(AT)) == NOACU)
return ("unknown ACU type");
if (*cp != '@') {
while (*cp) {
}
if ((acu = acutype(AT)) == NOACU)
return ("unknown ACU type");
if (*cp != '@') {
while (*cp) {
- for (phnum = cp;
any(*cp, "0123456789-*=K")
; cp++)
+ for (phnum = cp;
*cp && *cp != ','
; cp++)
;
if (*cp)
*cp++ = '\0';
;
if (*cp)
*cp++ = '\0';
@@
-98,9
+104,10
@@
connect()
fclose(fd);
return ("missing phone number");
}
fclose(fd);
return ("missing phone number");
}
- for (phnum = cp;
any(*cp, "0123456789-*=")
; cp++)
+ for (phnum = cp;
*cp && *cp != ',' && *cp != '\n'
; cp++)
;
;
- *cp = '\0';
+ if (*cp)
+ *cp++ = '\0';
if (conflag = (*acu->acu_dialer)(phnum, CU)) {
fclose(fd);
if (conflag = (*acu->acu_dialer)(phnum, CU)) {
fclose(fd);
@@
-124,9
+131,11
@@
connect()
disconnect(reason)
char *reason;
{
disconnect(reason)
char *reason;
{
- if (!conflag)
+ if (!conflag) {
+ logent(value(HOST), "", DV, "call terminated");
return;
return;
- if (reason != NOSTR) {
+ }
+ if (reason == NOSTR) {
logent(value(HOST), "", acu->acu_name, "call terminated");
if (boolean(value(VERBOSE)))
printf("\r\ndisconnecting...");
logent(value(HOST), "", acu->acu_name, "call terminated");
if (boolean(value(VERBOSE)))
printf("\r\ndisconnecting...");