home *** CD-ROM | disk | FTP | other *** search
- (**********************************************************************)
- (** Structure definitions for FMail v1.42g **)
- (** **)
- (** /* **)
- (** FMSTRUCT.H **)
- (** **)
- (** File structures for FMail 1.42g **)
- (** Copyright (C) 1998 Folkert J. Wijnstra. All rights reserved. **)
- (** **)
- (** All information in this document is subject to change at any **)
- (** time without prior notice! **)
- (** **)
- (** Strings are NUL terminated arrays of char type. **)
- (** Path names are \ terminated. **)
- (** */ **)
- (** **)
- (** Based on the C structures as published by Folkert Wijnstra. **)
- (** Converted to Delphi 3 by Eric Vaneberck **)
- (** **)
- (** Last update: 01 February 1998 **)
- (**********************************************************************)
-
- unit FMSTRUCT;
- interface
- uses
- {$IFDEF WIN32}
- Windows;
- {$ELSE}
- Wintypes, WinProcs;
- {$ENDIF}
-
- const
- fhandle = signed int;
- const
- u8 = unsigned char;
- const
- uchar = unsigned char;
- const
- schar = char;
- {$IFNDEF __32BIT__}
- const
- u16 = unsigned int;
- const
- s16 = signed int;
- {$ELSE}
- const
- u16 = short unsigned int;
- const
- s16 = short signed int;
- {$ENDIF}
- const
- u32 = long unsigned int;
- const
- s32 = long signed int;
- const
- udef = unsigned int;
- const
- sdef = signed int;
-
- const
- MAX_U32 = $FFFFFFFF;
-
-
- (****************************************************************************************************)
- (** General constants and structures **)
- (****************************************************************************************************)
-
- type
- archiverInfo = record
- programName: Array[0..46-1] of UCHAR;
- memRequired: U16;
- end {archiverInfo};
-
- type
- = UCHAR PATHTYPE[48];
-
- type
- nodeNumType = record
- zone: U16;
- net: U16;
- node: U16;
- point: U16;
- end {nodeNumType};
-
- type
- nodeFlagsTyp = record
- 1: UNSIGNED READONLY :;
- {= Bit 0 }
- 1: UNSIGNED WRITEONLY :;
- {= Bit 1 }
- 1: UNSIGNED LOCKED :;
- {= Bit 2 }
- 13: UNSIGNED RESERVED :;
- end {nodeFlagsTyp};
- type
- nodeNumXType = record
- nodeNum: NODENUMTYPE;
- flags: NODEFLAGSTYPE;
- end {nodeNumXType};
-
- type
- nodeFakeType = record
- nodeNum: NODENUMTYPE;
- fakeNet: U16;
- end {nodeFakeType};
-
-
- {+//********** File header structure***********/ }
-
- const
- DATATYPE_CF = $0102; {/* not used yet*/}
- const
- DATATYPE_NO = $0202; {/* node file*/}
- const
- DATATYPE_AD = $0401; {/* area file for echo mail defaults*/}
- const
- DATATYPE_AE = $0402; {/* area file for echo mail*/}
-
- type
- headerType = record
- versionString: Array[0..32-1] of UCHAR;
- {= Always starts with 'FMail' }
- revNumber: U16;
- {= Is now 0x0100 }
- const
- s = above*/;
- headerSize: U16;
- creationDate: S32;
- lastModified: S32;
- totalRecords: U16;
- recordSize: U16;
- end {headerType};
-
-
- {+// The structure below is used by the Areas File and (only partly) }
- {=by the Config File }
-
- type
- areaOptionsTyp = record
- 1: UNSIGNED ACTIVE :;
- {= Bit 0 }
- 1: UNSIGNED TINYSEENBY :;
- {= Bit 1 }
- 1: UNSIGNED SECURITY :;
- {= Bit 2 }
- 1: UNSIGNED :;
- {= Bit 3 }
- 1: UNSIGNED ALLOWPRIVATE:;
- {= Bit 4 }
- 1: UNSIGNED IMPSEENBY :;
- {= Bit 5 }
- 1: UNSIGNED CHECKSEENBY :;
- {= Bit 6 }
- 1: UNSIGNED :;
- {= Bit 7 }
- 1: UNSIGNED LOCAL :;
- {= Bit 8 }
- 1: UNSIGNED DISCONNECTED:;
- {= Bit 9 }
- 1: UNSIGNED _RESERVED :;
- {= Bit 10 }
- 1: UNSIGNED ALLOWAREAFIX:;
- {= Bit 11 }
- 1: UNSIGNED EXPORT2BBS :;
- {= Bit 12 }
- 1: UNSIGNED :;
- {= Bit 13 }
- 1: UNSIGNED ARRIVALDATE :;
- {= Bit 14 }
- 1: UNSIGNED SYSOPREAD :;
- end {areaOptionsTyp};
-
- (****************************************************************************************************)
- (** the structure of FMAIL.CFG **)
- (****************************************************************************************************)
-
- const
- MAX_AKAS = 32;
- const
- MAX_AKAS_F = 64;
- const
- MAX_AKAS_OLD = 16;
- const
- MAX_NA_OLD = 11;
- const
- MAX_NETAKAS = 32;
- const
- MAX_NETAKAS_F = 64;
- const
- MAX_USERS = 16;
- const
- MAX_UPLREQ = 32;
- const
- MAX_MATCH = 16; {// not used yet}
-
- const
- LOG_NEVER = $0000;
- const
- LOG_INBOUND = $0001;
- const
- LOG_OUTBOUND = $0002;
- const
- LOG_PKTINFO = $0004;
- const
- LOG_XPKTINFO = $0008;
- const
- LOG_UNEXPPWD = $0010;
- const
- LOG_SENTRCVD = $0020;
- const
- LOG_STATS = $0040;
- const
- LOG_PACK = $0080;
- const
- LOG_MSGBASE = $0100;
- const
- LOG_ECHOEXP = $0200;
- const
- LOG_NETIMP = $0400;
- const
- LOG_NETEXP = $0800;
- const
- LOG_OPENERR = $1000;
- const
- LOG_EXEC = $2000;
- const
- LOG_NOSCRN = $4000;
- const
- LOG_ALWAYS = $8000;
- const
- LOG_DEBUG = $8000;
-
- type
- = NODEFAKETYPE _AKALISTTYPE[MAX_AKAS_OLD];
- type
- = NODEFAKETYPE AKALISTTYPE[MAX_AKAS_F];
-
- type
- genOptionsTyp = record
- 1: UNSIGNED USEEMS :;
- {= BIT 0 }
- 1: UNSIGNED CHECKBREAK :;
- {= BIT 1 }
- 1: UNSIGNED SWAP :;
- {= BIT 2 }
- 1: UNSIGNED SWAPEMS :;
- {= BIT 3 }
- 1: UNSIGNED SWAPXMS :;
- {= BIT 4 }
- 1: UNSIGNED LFN :;
- {= BIT 5 }
- 1: UNSIGNED MONOCHROME :;
- {= BIT 6 }
- 1: UNSIGNED COMMENTFFD :;
- {= BIT 7 }
- 1: UNSIGNED PTAREASBBS :;
- {= BIT 8 }
- 1: UNSIGNED COMMENTFRA :;
- {= BIT 9 }
- 1: UNSIGNED :;
- {= BIT 10 }
- 1: UNSIGNED INCBDRRA :;
- {= BIT 11 }
- 1: UNSIGNED :;
- {= BIT 12 }
- 1: UNSIGNED TIMESLICEFM :;
- {= BIT 13 }
- 1: UNSIGNED TIMESLICEFT :;
- {= BIT 14 }
- 1: UNSIGNED _RA2 :;
- end {genOptionsTyp};
- type
- mailOptionsTyp = record
- 1: UNSIGNED REMOVENETKLUDGES :;
- {= Bit 0 }
- 1: UNSIGNED ADDPOINTTOPATH :;
- {= Bit 1 }
- 1: UNSIGNED CHECKPKTDEST :;
- {= Bit 2 }
- 1: UNSIGNED NEVERARC060 :;
- {= Bit 3 }
- 1: UNSIGNED CREATESEMA :;
- {= Bit 4 }
- 1: UNSIGNED DAILYMAIL :;
- {= Bit 5 }
- 1: UNSIGNED WARNNEWMAIL :;
- {= bit 6 }
- 1: UNSIGNED KILLBADFATT :;
- {= Bit 7 }
- 1: UNSIGNED DUPDETECTION :;
- {= Bit 8 }
- 1: UNSIGNED IGNOREMSGID :;
- {= Bit 9 }
- 1: UNSIGNED ARCMAIL060 :;
- {= Bit 10 }
- 1: UNSIGNED EXTNAMES :;
- {= Bit 11 }
- 1: UNSIGNED PERSNETMAIL :;
- {= Bit 12 }
- 1: UNSIGNED PRIVATEIMPORT :;
- {= Bit 13 }
- 1: UNSIGNED KEEPEXPNETMAIL :;
- {= Bit 14 }
- 1: UNSIGNED KILLEMPTYNETMAIL :;
- end {mailOptionsTyp};
- type
- mbOptionsTyp = record
- 1: UNSIGNED SORTNEW :;
- {= bit 0 }
- 1: UNSIGNED SORTSUBJECT :;
- {= bit 1 }
- 1: UNSIGNED UPDATECHAINS :;
- {= bit 2 }
- 1: UNSIGNED RETEAR :;
- {= bit 3 }
- 1: UNSIGNED :;
- {= bit 4 }
- 1: UNSIGNED :;
- {= bit 5 }
- 1: UNSIGNED REMOVERE :;
- {= bit 6 }
- 1: UNSIGNED REMOVELFSR :;
- {= bit 7 }
- 1: UNSIGNED SCANALWAYS :;
- {= bit 8 }
- 1: UNSIGNED SCANUPDATE :;
- {= bit 9 }
- 1: UNSIGNED MULTILINE :;
- {= bit 10 }
- 1: UNSIGNED :;
- {= bit 11 }
- 1: UNSIGNED QUICKTOSS :;
- {= bit 12 }
- 1: UNSIGNED CHECKNETBOARD:;
- {= bit 13 }
- 1: UNSIGNED :;
- {= bit 14 }
- 1: UNSIGNED SYSOPIMPORT :;
- end {mbOptionsTyp};
- type
- mgrOptionsTyp = record
- 1: UNSIGNED KEEPREQUEST :;
- {= Bit 0 }
- 1: UNSIGNED KEEPRECEIPT :;
- {= Bit 1 }
- 1: UNSIGNED SENDUPLARLIST:;
- {= Bit 2 }
- 1: UNSIGNED :;
- {= Bit 3 }
- 1: UNSIGNED AUTODISCAREA :;
- {= Bit 4 }
- 1: UNSIGNED AUTODISCDEL :;
- {= Bit 5 has temp. no effect, rec is always deleted }
- 3: UNSIGNED :;
- {= Bit 6-8 }
- 1: UNSIGNED ALLOWADDALL :;
- {= Bit 9 }
- 1: UNSIGNED ALLOWACTIVE :;
- {= Bit 10 }
- 1: UNSIGNED ALLOWBCL :;
- {= Bit 11 }
- 1: UNSIGNED ALLOWPASSWORD:;
- {= Bit 12 }
- 1: UNSIGNED ALLOWPKTPWD :;
- {= Bit 13 }
- 1: UNSIGNED ALLOWNOTIFY :;
- {= Bit 14 }
- 1: UNSIGNED ALLOWCOMPR :;
- end {mgrOptionsTyp};
- IFDEF = mgrOptionsTyp;
- 0 = mgrOptionsTyp;
- type
- defaultOptionsTyp = record
- 1: UNSIGNED ACTIVE :;
- {= Bit 0 }
- 1: UNSIGNED TINYSEENBY :;
- {= Bit 1 }
- 1: UNSIGNED SECURITY :;
- {= Bit 2 }
- 1: UNSIGNED :;
- {= Bit 3 }
- 1: UNSIGNED ALLOWPRIVATE:;
- {= Bit 4 }
- 1: UNSIGNED IMPSEENBY :;
- {= Bit 5 }
- 1: UNSIGNED CHECKSEENBY :;
- {= Bit 6 }
- 1: UNSIGNED :;
- {= Bit 7 }
- 1: UNSIGNED LOCAL :;
- {= Bit 8 }
- 1: UNSIGNED :;
- {= Bit 9 }
- 1: UNSIGNED PASSTHROUGH :;
- {= Bit 10 }
- 3: UNSIGNED :;
- {= Bit 11-13 }
- 1: UNSIGNED ARRIVALDATE :;
- {= Bit 14 }
- 1: UNSIGNED SYSOPREAD :;
- end {defaultOptionsTyp};
- ENDIF = defaultOptionsTyp;
- type
- uplOptType = record
- 1: UNSIGNED ADDPLUSPREFIX :;
- {= BIT 0 }
- 3: UNSIGNED :;
- 1: UNSIGNED UNCONDITIONAL :;
- {= BIT 4 }
- 11: UNSIGNED :;
- end {uplOptType};
-
- type
- userType = record
- userName: Array[0..36-1] of UCHAR;
- reserved: Array[0..28-1] of UCHAR;
- end {userType};
-
- type
- uplinkReqType = record
- node: NODENUMTYPE;
- program: Array[0..9-1] of UCHAR;
- password: Array[0..17-1] of UCHAR;
- fileName: Array[0..13-1] of UCHAR;
- fileType: UCHAR;
- groups: U32;
- originAka: UCHAR;
- options: UPLOPTTYPE;
- reserved: Array[0..9-1] of UCHAR;
- end {uplinkReqType};
-
- type
- akaMatchNodeType = record
- valid: U16;
- zone: U16;
- net: U16;
- node: U16;
- end {akaMatchNodeType};
-
- type
- akaMatchType = record
- amNode: AKAMATCHNODETYPE;
- aka: U16;
- end {akaMatchType};
-
- {+// ATTENTION: FMAIL.CFG does NOT use the new config file type yet (no header) !!!*/ }
-
- type
- configType = record
- versionMajor: UCHAR;
- versionMinor: UCHAR;
- creationDate: S32;
- key: U32;
- reservedKey: U32;
- relKey1: U32;
- relKey2: U32;
- reserved1: Array[0..20-1] of UCHAR;
- maxForward: U16;
- mgrOptions: MGROPTIONSTYPE;
- _akaList: _AKALISTTYPE;
- _netmailBoard: Array[0..MAX_NA_OLD-1] of U16;
- _reservedNet: Array[0..16-MAX_NA_OLD-1] of U16;
- genOptions: GENOPTIONSTYPE;
- mbOptions: MBOPTIONSTYPE;
- mailOptions: MAILOPTIONSTYPE;
- maxPktSize: U16;
- kDupRecs: U16;
- mailer: U16;
- bbsProgram: U16;
- maxBundleSize: U16;
- extraHandles: U16;
- {= 0-235 }
- autoRenumber: U16;
- bufSize: U16;
- ftBufSize: U16;
- allowedNumNetmail: U16;
- logInfo: U16;
- logStyle: U16;
- activTimeOut: U16;
- maxMsgSize: U16;
- reserved2: Array[0..64-1] of UCHAR;
- colorSet: U16;
- sysopName: Array[0..36-1] of UCHAR;
- defaultArc: U16;
- _adiscDaysNode: U16;
- _adiscDaysPoint: U16;
- _adiscSizeNode: U16;
- _adiscSizePoint: U16;
- reserved3: Array[0..16-1] of UCHAR;
- tearType: UCHAR;
- tearLine: Array[0..25-1] of UCHAR;
- summaryLogName: PATHTYPE;
- recBoard: U16;
- badBoard: U16;
- dupBoard: U16;
- topic1: Array[0..16-1] of UCHAR;
- topic2: Array[0..16-1] of UCHAR;
- bbsPath: PATHTYPE;
- netPath: PATHTYPE;
- sentPath: PATHTYPE;
- rcvdPath: PATHTYPE;
- inPath: PATHTYPE;
- outPath: PATHTYPE;
- securePath: PATHTYPE;
- logName: PATHTYPE;
- swapPath: PATHTYPE;
- semaphorePath: PATHTYPE;
- pmailPath: PATHTYPE;
- areaMgrLogName: PATHTYPE;
- autoRAPath: PATHTYPE;
- autoFolderFdPath: PATHTYPE;
- autoAreasBBSPath: PATHTYPE;
- autoGoldEdAreasPath: PATHTYPE;
- unArc: ARCHIVERINFO;
- unZip: ARCHIVERINFO;
- unLzh: ARCHIVERINFO;
- unPak: ARCHIVERINFO;
- unZoo: ARCHIVERINFO;
- unArj: ARCHIVERINFO;
- unSqz: ARCHIVERINFO;
- GUS: ARCHIVERINFO;
- arc: ARCHIVERINFO;
- zip: ARCHIVERINFO;
- lzh: ARCHIVERINFO;
- pak: ARCHIVERINFO;
- zoo: ARCHIVERINFO;
- arj: ARCHIVERINFO;
- sqz: ARCHIVERINFO;
- customArc: ARCHIVERINFO;
- autoFMail102Path: PATHTYPE;
- reserved4: Array[0..35-1] of UCHAR;
- _optionsAKA: Array[0..MAX_NA_OLD-1] of AREAOPTIONSTYPE;
- _groupsQBBS: Array[0..MAX_NA_OLD-1] of UCHAR;
- _templateSecQBBS: Array[0..MAX_NA_OLD-1] of U16;
- _templateFlagsQBBS: Array[0..MAX_NA_OLD-1] of: Array[0..4-1] of UCHAR;
- _attr2RA: Array[0..MAX_NA_OLD-1] of UCHAR;
- _aliasesQBBS: Array[0..MAX_NA_OLD-1] of UCHAR;
- _groupRA: Array[0..MAX_NA_OLD-1] of U16;
- _altGroupRA: Array[0..MAX_NA_OLD-1] of: Array[0..3-1] of U16;
- _qwkName: Array[0..MAX_NA_OLD-1] of: Array[0..13-1] of UCHAR;
- _minAgeSBBS: Array[0..MAX_NA_OLD-1] of U16;
- _daysRcvdAKA: Array[0..MAX_NA_OLD-1] of U16;
- _replyStatSBBS: Array[0..MAX_NA_OLD-1] of UCHAR;
- _attrSBBS: Array[0..MAX_NA_OLD-1] of U16;
- groupDescr: Array[0..26-1] of: Array[0..27-1] of UCHAR;
- reserved5: Array[0..9-1] of UCHAR;
- _msgKindsRA: Array[0..MAX_NA_OLD-1] of UCHAR;
- _attrRA: Array[0..MAX_NA_OLD-1] of UCHAR;
- _readSecRA: Array[0..MAX_NA_OLD-1] of U16;
- _readFlagsRA: Array[0..MAX_NA_OLD-1] of: Array[0..4-1] of UCHAR;
- _writeSecRA: Array[0..MAX_NA_OLD-1] of U16;
- _writeFlagsRA: Array[0..MAX_NA_OLD-1] of: Array[0..4-1] of UCHAR;
- _sysopSecRA: Array[0..MAX_NA_OLD-1] of U16;
- _sysopFlagsRA: Array[0..MAX_NA_OLD-1] of: Array[0..4-1] of UCHAR;
- _daysAKA: Array[0..MAX_NA_OLD-1] of U16;
- _msgsAKA: Array[0..MAX_NA_OLD-1] of U16;
- _descrAKA: Array[0..MAX_NA_OLD-1] of: Array[0..51-1] of UCHAR;
- users: Array[0..MAX_USERS-1] of USERTYPE;
- akaMatch: Array[0..MAX_MATCH-1] of AKAMATCHTYPE;
- MAX_MATCH-1] of: PUCHAR RESERVED6[992-10;
- tossedAreasList: PATHTYPE;
- sentEchoPath: PATHTYPE;
- preUnarc: ARCHIVERINFO;
- postUnarc: ARCHIVERINFO;
- preArc: ARCHIVERINFO;
- postArc: ARCHIVERINFO;
- unUc2: ARCHIVERINFO;
- unRar: ARCHIVERINFO;
- unJar: ARCHIVERINFO;
- resUnpack: Array[0..5-1] of ARCHIVERINFO;
- uc2: ARCHIVERINFO;
- rar: ARCHIVERINFO;
- jar: ARCHIVERINFO;
- resPack: Array[0..5-1] of ARCHIVERINFO;
- uplinkReq: Array[0..MAX_UPLREQ+32-1] of UPLINKREQTYPE;
- unArc32: ARCHIVERINFO;
- unZip32: ARCHIVERINFO;
- unLzh32: ARCHIVERINFO;
- unPak32: ARCHIVERINFO;
- unZoo32: ARCHIVERINFO;
- unArj32: ARCHIVERINFO;
- unSqz32: ARCHIVERINFO;
- unUc232: ARCHIVERINFO;
- unRar32: ARCHIVERINFO;
- GUS32: ARCHIVERINFO;
- unJar32: ARCHIVERINFO;
- resUnpack32: Array[0..5-1] of ARCHIVERINFO;
- preUnarc32: ARCHIVERINFO;
- postUnarc32: ARCHIVERINFO;
- arc32: ARCHIVERINFO;
- zip32: ARCHIVERINFO;
- lzh32: ARCHIVERINFO;
- pak32: ARCHIVERINFO;
- zoo32: ARCHIVERINFO;
- arj32: ARCHIVERINFO;
- sqz32: ARCHIVERINFO;
- uc232: ARCHIVERINFO;
- rar32: ARCHIVERINFO;
- customArc32: ARCHIVERINFO;
- jar32: ARCHIVERINFO;
- resPack32: Array[0..5-1] of ARCHIVERINFO;
- preArc32: ARCHIVERINFO;
- postArc32: ARCHIVERINFO;
- descrAKA: Array[0..MAX_NETAKAS-1] of: Array[0..51-1] of UCHAR;
- qwkName: Array[0..MAX_NETAKAS-1] of: Array[0..13-1] of UCHAR;
- optionsAKA: Array[0..MAX_NETAKAS-1] of AREAOPTIONSTYPE;
- msgKindsRA: Array[0..MAX_NETAKAS-1] of UCHAR;
- daysAKA: Array[0..MAX_NETAKAS-1] of U16;
- msgsAKA: Array[0..MAX_NETAKAS-1] of U16;
- groupsQBBS: Array[0..MAX_NETAKAS-1] of UCHAR;
- attrRA: Array[0..MAX_NETAKAS-1] of UCHAR;
- attr2RA: Array[0..MAX_NETAKAS-1] of UCHAR;
- attrSBBS: Array[0..MAX_NETAKAS-1] of U16;
- aliasesQBBS: Array[0..MAX_NETAKAS-1] of UCHAR;
- groupRA: Array[0..MAX_NETAKAS-1] of U16;
- altGroupRA: Array[0..MAX_NETAKAS-1] of: Array[0..3-1] of U16;
- minAgeSBBS: Array[0..MAX_NETAKAS-1] of U16;
- daysRcvdAKA: Array[0..MAX_NETAKAS-1] of U16;
- replyStatSBBS: Array[0..MAX_NETAKAS-1] of UCHAR;
- readSecRA: Array[0..MAX_NETAKAS-1] of U16;
- readFlagsRA: Array[0..MAX_NETAKAS-1] of: Array[0..8-1] of UCHAR;
- writeSecRA: Array[0..MAX_NETAKAS-1] of U16;
- writeFlagsRA: Array[0..MAX_NETAKAS-1] of: Array[0..8-1] of UCHAR;
- sysopSecRA: Array[0..MAX_NETAKAS-1] of U16;
- sysopFlagsRA: Array[0..MAX_NETAKAS-1] of: Array[0..8-1] of UCHAR;
- templateSecQBBS: Array[0..MAX_NETAKAS-1] of U16;
- templateFlagsQBBS: Array[0..MAX_NETAKAS-1] of: Array[0..8-1] of UCHAR;
- reserved7: Array[0..512-1] of UCHAR;
- netmailBoard: Array[0..MAX_NETAKAS_F-1] of U16;
- akaList: AKALISTTYPE;
- end {configType};
-
-
- (****************************************************************************************************)
- (** Area Manager **)
- (****************************************************************************************************)
-
- {$IFDEF __FMAILX__ || defined(__32BIT__)}
- const
- MAX_AREAS = 4096;
- {$ELSE}
- const
- MAX_AREAS = 512;
- {$ENDIF}
-
- const
- MAX_FORWARD = 64;
- const
- MAX_FORWARDOLD = 64;
- const
- MAX_FORWARDDEF = 256; {// NOTE: this is a dummy. 'config.maxForward'}
- {/// contains the real size. 256 is the maximum. }
- const
- MAX_FORWARD = config.maxForward;
- const
- RAWECHO_SIZE = sizeof(rawEchoType);
-
- const
- MB_PATH_LEN_OLD = 19;
- const
- MB_PATH_LEN = 61;
- const
- ECHONAME_LEN_090 = 25;
- const
- ECHONAME_LEN = 51;
- const
- COMMENT_LEN = 51;
- const
- ORGLINE_LEN = 59;
-
- type
- = UCHAR AREANAMETYPE[ECHONAME_LEN];
-
- {+// NOTE: See above for the file header structure !!!*/ }
-
- type
- areaStatTyp = record
- 1: UNSIGNED TOSSEDTO :;
- {= BIT 0 }
- 15: UNSIGNED :;
- end {areaStatTyp};
- type
- rawEchoType = record
- signature: U16;
- {= contains "AE" for echo areas in FMAIL.AR and }
- {+// "AD" for default settings in FMAIL.ARD*/ }
- writeLevel: U16;
- areaName: AREANAMETYPE;
- comment: Array[0..COMMENT_LEN-1] of UCHAR;
- options: AREAOPTIONSTYPE;
- boardNumRA: U16;
- msgBaseType: UCHAR;
- msgBasePath: Array[0..MB_PATH_LEN-1] of UCHAR;
- board: U16;
- originLine: Array[0..ORGLINE_LEN-1] of UCHAR;
- address: U16;
- group: U32;
- _alsoSeenBy: U16;
- {= obsolete: see the 32-bit alsoSeenBy below }
- msgs: U16;
- days: U16;
- daysRcvd: U16;
- {+// old startposition of export[MAX_FORWARD]*/ }
- readSecRA: U16;
- flagsRdRA: Array[0..4-1] of UCHAR;
- flagsRdNotRA: Array[0..4-1] of UCHAR;
- writeSecRA: U16;
- flagsWrRA: Array[0..4-1] of UCHAR;
- flagsWrNotRA: Array[0..4-1] of UCHAR;
- sysopSecRA: U16;
- flagsSysRA: Array[0..4-1] of UCHAR;
- flagsSysNotRA: Array[0..4-1] of UCHAR;
- templateSecQBBS: U16;
- flagsTemplateQBBS: Array[0..4-1] of UCHAR;
- _internalUse: UCHAR;
- netReplyBoardRA: U16;
- boardTypeRA: UCHAR;
- attrRA: UCHAR;
- attr2RA: UCHAR;
- groupRA: U16;
- altGroupRA: Array[0..3-1] of U16;
- msgKindsRA: UCHAR;
- qwkName: Array[0..13-1] of UCHAR;
- minAgeSBBS: U16;
- attrSBBS: U16;
- replyStatSBBS: UCHAR;
- groupsQBBS: UCHAR;
- aliasesQBBS: UCHAR;
- lastMsgTossDat: U32;
- lastMsgScanDat: U32;
- alsoSeenBy: U32;
- stat: AREASTATTYPE;
- reserved: Array[0..180-1] of UCHAR;
- export: Array[0..MAX_FORWARDDEF-1] of NODENUMXTYPE;
- end {rawEchoType};
-
-
- (****************************************************************************************************)
- (** Node manager **)
- (****************************************************************************************************)
-
- {$IFDEF __32BIT__ || defined __FMAILX__}
- const
- MAX_NODEMGR = 1024;
- {$ELSE}
- const
- MAX_NODEMGR = 256;
- {$ENDIF}
-
- const
- PKTOUT_PATH_LEN = 53;
-
- const
- PKT_TYPE_2PLUS = 1;
- const
- CAPABILITY = PKT_TYPE_2PLUS;
-
- type
- nodeOptionsType = record
- 1: UNSIGNED FIXDATE :;
- {= Bit 0 }
- 1: UNSIGNED TINYSEENBY :;
- {= Bit 1 }
- 1: UNSIGNED :;
- {= Bit 2 }
- 1: UNSIGNED IGNOREPWD :;
- {= Bit 3 }
- 1: UNSIGNED ACTIVE :;
- {= Bit 4 }
- 1: UNSIGNED :;
- 1: UNSIGNED ROUTETOPOINT:;
- {= Bit 6 }
- 1: UNSIGNED PACKNETMAIL :;
- {= Bit 7 }
- 1: UNSIGNED :;
- {= Bit 8 }
- 3: UNSIGNED :;
- 1: UNSIGNED FORWARDREQ :;
- {= Bit 12 }
- 1: UNSIGNED REMMAINT :;
- {= Bit 13 }
- 1: UNSIGNED ALLOWRESCAN :;
- {= Bit 14 }
- 1: UNSIGNED NOTIFY :;
- end {nodeOptionsType};
-
- type
- nodeInfoTypeOld = record
- }: = OLD !!!;
- {
- node: NODENUMTYPE;
- reserved1: Array[0..2-1] of UCHAR;
- capability: U16;
- archiver: U16;
- options: NODEOPTIONSTYPE;
- groups: U32;
- outStatus: U16;
- reserved2: Array[0..32-1] of UCHAR;
- password: Array[0..18-1] of UCHAR;
- packetPwd: Array[0..10-1] of UCHAR;
- reserved: Array[0..2-1] of UCHAR;
- viaNode: NODENUMTYPE;
- sysopName: Array[0..36-1] of UCHAR;
- end {nodeInfoTypeOld};
-
- {+// NOTE: see above for the file header structure !!!*/ }
-
- type
- nodeInfoType = record
- signature: U16;
- {= contains "ND" }
- writeLevel: U16;
- node: NODENUMTYPE;
- viaNode: NODENUMTYPE;
- capability: U16;
- options: NODEOPTIONSTYPE;
- archiver: U8;
- reserved1: U8;
- groups: U32;
- outStatus: U16;
- sysopName: Array[0..36-1] of UCHAR;
- password: Array[0..18-1] of UCHAR;
- packetPwd: Array[0..9-1] of UCHAR;
- useAka: UCHAR;
- lastMsgRcvdDat: U32;
- lastMsgSentDat: U32;
- lastNewBundleDat: U32;
- pktOutPath: Array[0..PKTOUT_PATH_LEN-1] of UCHAR;
- passiveDays: U16;
- passiveSize: U16;
- lastSentBCL: U32;
- autoBCL: U16;
- _lastNewBundleDat: U32;
- reserved2: Array[0..17-1] of UCHAR;
- end {nodeInfoType};
-
- (****************************************************************************************************)
- (** Pack Manager **)
- (****************************************************************************************************)
-
- const
- PACK_STR_SIZE = 64;
- const
- MAX_PACK = 128;
-
- type
- = UCHAR PACKENTRYTYPE[PACK_STR_SIZE];
- type
- = PACKENTRYTYPE PACKTYPE[MAX_PACK];
-
-
- (****************************************************************************************************)
- (** FMAIL.BDE **)
- (****************************************************************************************************)
-
- const
- MAX_BAD_ECHOS = 50;
-
- type
- badEchoType = record
- badEchoName: AREANAMETYPE;
- srcNode: NODENUMTYPE;
- destAka: S16;
- end {badEchoType};
-
-
-
- var
- DLLLoaded: Boolean { is DLL (dynamically) loaded already? }
- {$IFDEF WIN32} = False; {$ENDIF}
-
- implementation
-
- var
- SaveExit: pointer;
- DLLHandle: THandle;
- {$IFNDEF MSDOS}
- ErrorMode: Integer;
- {$ENDIF}
-
- procedure NewExit; far;
- begin
- ExitProc := SaveExit;
- FreeLibrary(DLLHandle)
- end {NewExit};
-
- procedure LoadDLL;
- begin
- if DLLLoaded then Exit;
- {$IFNDEF MSDOS}
- ErrorMode := SetErrorMode($8000{SEM_NoOpenFileErrorBox});
- {$ENDIF}
- DLLHandle := LoadLibrary('FMSTRUCT.DLL');
- if DLLHandle >= 32 then
- begin
- DLLLoaded := True;
- SaveExit := ExitProc;
- ExitProc := @NewExit;
- end
- else
- begin
- DLLLoaded := False;
- { Error: FMSTRUCT.DLL could not be loaded !! }
- end;
- {$IFNDEF MSDOS}
- SetErrorMode(ErrorMode)
- {$ENDIF}
- end {LoadDLL};
-
- begin
- LoadDLL;
- end.
-