#ifndef DSCSTD_DEFINED #define DSCSTD_DEFINED 1 #undef __VAX #ifdef VAXC #define __VAX #endif /* these headers are so common that i always include them */ #include #include #include /* these three macros are used _only_ in a function declaration or prototype; * the first marks it for grepping (Module Entry Point) while the second and * third are used to indicated the scope */ #define MEP__ #define UNIVERSAL #define PUBLIC #define PRIVATE static /* indicate the scope of the data */ #define LOCALDATA static /* definition of an internal value */ #define GLOBALDATA /* definition of an external value */ #define IMPORTDATA extern /* reference of an external value which is defined in another module */ typedef int BOOL; typedef unsigned long CONDVAL; /* these three structures should be supplied by digital :-( */ typedef struct VMS_ITEM_LIST { unsigned short itemsize; unsigned short itemcode; void *itemaddr; void *itemlen; /* address of either an unsigned short (usual) or an unsigned long (getlki) */ } ItemList; typedef struct GENERIC_IOSB { unsigned short cond; /* the status of the i/o --- a SS$_XXXXX value */ unsigned short retlen; /* the number of characters written into the buffer before */ unsigned char filler[4]; } IOStatusBlock; typedef struct LONGWORD_STATUS_IOSB { CONDVAL cond; /* some of the newer system services use a full longword for the status value */ long other; /* function specific */ } LongIOStatBlock; /* the data structure used by SYS$NUMTIM() system service */ typedef struct VMS_DELTA_TIMEBUFFER { long zUnused; unsigned short nDays; unsigned short nHours; unsigned short nMinutes; unsigned short nSeconds; unsigned short nCentiseconds; } DeltaTimeBuf; /* two macros to check the low bit for success or failure */ #include #define IFGOOD(f) cv0 = (CONDVAL) (f); if ((cv0 & STS$M_SUCCESS) == STS$K_SUCCESS) #define IFBAD(f) cv0 = (CONDVAL) (f); if ((cv0 & STS$M_SUCCESS) != STS$K_SUCCESS) #define MAXSIZE_ACCOUNT 8 #define MAXSIZE_DEVICELOCKNAME 64 #define MAXSIZE_DEVICENAME 64 #define MAXSIZE_FULLNODENAME 15 #define MAXSIZE_HWNAME 31 #define MAXSIZE_IDENTIFIER (1 + 31 + 1 + 31 + 1) #define MAXSIZE_LOCKNAME 31 #define MAXSIZE_NODENAME 6 #define MAXSIZE_PROCESSNAME 15 #define MAXSIZE_QUEUENAME 31 #define MAXSIZE_SYSTEMVERSION 8 #define MAXSIZE_TERMINAL 8 #define MAXSIZE_USERNAME 12 #define MAXSIZE_VOLUMENAME 12 #endif