/* Mark5Com.h * To go with Mark5Com.c, which now also includes Error5Com.c * Revised: 2002 August 27, JAB */ #ifndef MARK5COM #define MARK5COM 1 #include #include /* For strcmp(), etc. */ #include /* For atoi() */ #include /* For socket() and connect() */ #include /* For socket() and connect() */ #include /* For socket() with PF_INET */ #include /* For getservbyname() and gethostbyname() */ #include /* For close() */ #ifndef MAXCOMMENTS /* In vex.h */ /* Why should I have to do this?? */ # include "vex.h" /* In $INC */ #endif #ifndef TRUE # define TRUE 1 # define FALSE 0 #endif extern int h_errno; /* From gethostbyname() for herror() */ extern void herror(const char * s); /* Needed on HP-UX */ /* Why (!) isn't this in one of these includes on HP-UX? */ extern char * me; /* My name */ extern int msglev; /* Debug level */ struct Machn { /* Each possible Mark-5 machine */ char name[64]; /* Machine name (or null if not in use) */ int sock; /* Socket (-1 if not in use) */ FILE * fsock; /* Sock also as a stream */ char outLine[1024]; /* Answer to last command or query */ }; char * Mark5Com (char * machine, char * inLine); int Error5Com (char * astring); int TOT5Com (char * astring, double * ptot, long long * pbyte); int DiskInfo(char * machine, struct discinfo * dnfo); #endif