Commit | Line | Data |
---|---|---|
6ca29c5c TL |
1 | #include "stdio.h" |
2 | /* some system names */ | |
3 | #define MYNAME "vax135" | |
4 | ||
5 | #define THISDIR "/usr/lib/uucp" | |
6 | #define SQFILE "/usr/lib/uucp/SQFILE" | |
7 | #define SQTMP "/usr/lib/uucp/SQTMP" | |
8 | #define SYSFILE "/usr/lib/uucp/L.sys" | |
9 | #define SYSFILECR "/usr/lib/uucp/L.sys.cr" | |
10 | #define DEVFILE "/usr/lib/uucp/L-devices" | |
11 | #define DIALFILE "/usr/lib/uucp/L-dialcodes" | |
12 | #define USERFILE "/usr/lib/uucp/USERFILE" | |
13 | ||
14 | #define SPOOL "/usr/spool/uucp" | |
15 | #define LOGDIR "/usr/spool/uucp" | |
16 | #define SEQFILE "/usr/spool/uucp/SEQF" | |
17 | #define SQLOCK "/usr/spool/uucp/LCK.SQ" | |
18 | #define SYSLOG "/usr/spool/uucp/SYSLOG" | |
19 | #define XQTDIR "/usr/spool/uucp/.XQTDIR" | |
20 | ||
21 | #define SEQLOCK "LCK.SEQL" | |
22 | #define CMDPRE 'C' | |
23 | #define DATAPRE 'D' | |
24 | #define XQTPRE 'X' | |
25 | ||
26 | #define LOGPREFIX "LOG." | |
27 | #define LOGLOCK "/usr/spool/uucp/LCK.LOG" | |
28 | #define LOGFILE "/usr/spool/uucp/LOGFILE" | |
29 | ||
30 | #define RMTDEBUG "AUDIT" | |
31 | #define SQTIME 60L | |
32 | ||
33 | #define DEBUG(l, f, s) if (Debug >= l) fprintf(stderr, f, s) | |
34 | ||
35 | #define ASSERT(e, f, v) if (!(e)) {\ | |
36 | fprintf(stderr, "AERROR - (%s) ", "e");\ | |
37 | fprintf(stderr, f, v);\ | |
38 | cleanup(FAIL);}; | |
39 | ||
40 | #define FMV(p, n) close(n); dup(p[n]); close(p[n]); | |
41 | ||
42 | #define SAME 0 | |
43 | #define FAIL -1 | |
44 | #define SUCCESS 0 | |
45 | #define MASTER 1 | |
46 | #define SLAVE 0 | |
47 | #define MAXFULLNAME 100 | |
48 | #define MAXMSGTIME 45 | |
49 | #define MAXCHARTIME 15 | |
50 | #define NAMESIZE 15 | |
51 | #define ACULAST "-<" | |
52 | #define EOTMSG "\004\n\004\n" | |
53 | #define CALLBACK 1 | |
54 | #define LINKLEVEL 1 | |
55 | #define ANYREAD 04 | |
56 | ||
57 | /* commands */ | |
58 | #define SHELL "/bin/sh" | |
59 | #define MAIL "mail" | |
60 | #define UUCICO "/usr/lib/uucp/uucico" | |
61 | #define UUXQT "/usr/lib/uucp/uuxqt" | |
62 | #define UUCP "usr/lib/uucp/uucp" | |
63 | ||
64 | ||
65 | /* call connect fail stuff */ | |
66 | #define CF_SYSTEM -1 | |
67 | #define CF_TIME -2 | |
68 | #define CF_LOCK -3 | |
69 | #define CF_DIAL -5 | |
70 | #define CF_LOGIN -6 | |
71 | ||
72 | /* system status stuff */ | |
73 | #define SS_OK 0 | |
74 | #define SS_FAIL 4 | |
75 | #define SS_NODEVICE 1 | |
76 | #define SS_CALLBACK 2 | |
77 | #define SS_INPROGRESS 3 | |
78 | #define SS_BADSEQ 5 | |
79 | ||
80 | /* fail/retry parameters */ | |
81 | #define RETRYTIME 3300L | |
82 | #define INPROGTIME 7200L | |
83 | #define MAXRECALLS 10 | |
84 | ||
85 | /* stuff for command execution */ | |
86 | #define X_RQDFILE 'F' | |
87 | #define X_STDIN 'I' | |
88 | #define X_STDOUT 'O' | |
89 | #define X_CMD 'C' | |
90 | #define X_USER 'U' | |
91 | #define X_SENDFILE 'S' | |
92 | #define X_LOCK "LCK.XQT" | |
93 | #define X_LOCKTIME 3600L | |
94 | ||
95 | int Ifn, Ofn; | |
96 | char Rmtname[10]; | |
97 | char User[10]; | |
98 | char Loginuser[10]; | |
99 | char *Thisdir; | |
100 | char *Spool; | |
101 | char *Myname; | |
102 | char *Sysfiles[]; | |
103 | char *Devfile; | |
104 | char *Dialfile; | |
105 | int Debug; | |
106 | int Pkdebug; | |
107 | int Pkdrvon; | |
108 | int Bspeed; | |
109 | ||
110 | /* the define geteuid should be deleted if the */ | |
111 | /* routine is available in the libc.a library. */ | |
112 | #define geteuid getuid | |
113 | ||
114 | #define WKDSIZE 100 /* size of work dir name */ | |
115 | char Wrkdir[WKDSIZE]; |