Changed ulong type to uint32_t
This commit is contained in:
@@ -138,7 +138,6 @@ typedef int16_t sshort;
|
||||
typedef uint16_t ushort;
|
||||
|
||||
typedef uint32_t dword;
|
||||
typedef uint32_t ulong;
|
||||
#endif //#ifdef _MSC_VER
|
||||
|
||||
typedef uint8_t bit;
|
||||
|
@@ -73,9 +73,9 @@ struct _FDCtl {
|
||||
// ------------------------------------------------------------------
|
||||
// Masks for the nlofs member
|
||||
|
||||
const ulong IN_FDNODE = 0x01000000UL; // Data in FDNODE.FD
|
||||
const ulong IN_FDNET = 0x10000000UL; // Data in FDNET.PVT
|
||||
const ulong IN_FDPOINT = 0x20000000UL; // Data in FDPOINT.PVT
|
||||
const uint32_t IN_FDNODE = 0x01000000UL; // Data in FDNODE.FD
|
||||
const uint32_t IN_FDNET = 0x10000000UL; // Data in FDNET.PVT
|
||||
const uint32_t IN_FDPOINT = 0x20000000UL; // Data in FDPOINT.PVT
|
||||
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
@@ -104,17 +104,17 @@ struct ThrowIndex {
|
||||
// ------------------------------------------------------------------
|
||||
// Internal vars
|
||||
|
||||
int throw_inited = 0;
|
||||
int throw_count;
|
||||
ulong throw_allocations = 0;
|
||||
Throw throw_alloclist;
|
||||
int throw_max_count = 0;
|
||||
Throw** throw_index = NULL;
|
||||
int throw_index_size = 0;
|
||||
int throw_index_free = 0;
|
||||
int throw_last_free = -1;
|
||||
ulong throw_index_cache_hits = 0;
|
||||
int throw_overhead = sizeof(Throw) - 1;
|
||||
int throw_inited = 0;
|
||||
int throw_count;
|
||||
uint32_t throw_allocations = 0;
|
||||
Throw throw_alloclist;
|
||||
int throw_max_count = 0;
|
||||
Throw** throw_index = NULL;
|
||||
int throw_index_size = 0;
|
||||
int throw_index_free = 0;
|
||||
int throw_last_free = -1;
|
||||
uint32_t throw_index_cache_hits = 0;
|
||||
int throw_overhead = sizeof(Throw) - 1;
|
||||
|
||||
#define throw_index_init_size 1000
|
||||
#define throw_index_increment 100
|
||||
@@ -193,7 +193,7 @@ Throw* throw_find_overrun(Throw* pointer) {
|
||||
long last_diff = LONG_MAX;
|
||||
Throw** i = throw_index;
|
||||
for(int n=0; n<throw_index_size; n++,i++) {
|
||||
long diff = (ulong)*i - (ulong)pointer;
|
||||
long diff = (uint32_t)*i - (uint32_t)pointer;
|
||||
if((diff > 0) and (diff < last_diff)) {
|
||||
last_candidate = *i;
|
||||
last_diff = diff;
|
||||
@@ -211,7 +211,7 @@ Throw* throw_find_underrun(Throw* pointer) {
|
||||
long last_diff = LONG_MAX;
|
||||
Throw** i = throw_index;
|
||||
for(int n=0; n<throw_index_size; n++,i++) {
|
||||
long diff = (ulong)pointer - (ulong)*i;
|
||||
long diff = (uint32_t)pointer - (uint32_t)*i;
|
||||
if((diff > 0) and (diff < last_diff)) {
|
||||
last_candidate = *i;
|
||||
last_diff = diff;
|
||||
|
@@ -112,41 +112,41 @@ public:
|
||||
inline uint flags() { return r.w.flags; }
|
||||
#endif
|
||||
|
||||
inline void al(ulong b) { r.h.al = (byte)b; }
|
||||
inline void ah(ulong b) { r.h.ah = (byte)b; }
|
||||
inline void bl(ulong b) { r.h.bl = (byte)b; }
|
||||
inline void bh(ulong b) { r.h.bh = (byte)b; }
|
||||
inline void cl(ulong b) { r.h.cl = (byte)b; }
|
||||
inline void ch(ulong b) { r.h.ch = (byte)b; }
|
||||
inline void dl(ulong b) { r.h.dl = (byte)b; }
|
||||
inline void dh(ulong b) { r.h.dh = (byte)b; }
|
||||
inline void al(uint32_t b) { r.h.al = (byte)b; }
|
||||
inline void ah(uint32_t b) { r.h.ah = (byte)b; }
|
||||
inline void bl(uint32_t b) { r.h.bl = (byte)b; }
|
||||
inline void bh(uint32_t b) { r.h.bh = (byte)b; }
|
||||
inline void cl(uint32_t b) { r.h.cl = (byte)b; }
|
||||
inline void ch(uint32_t b) { r.h.ch = (byte)b; }
|
||||
inline void dl(uint32_t b) { r.h.dl = (byte)b; }
|
||||
inline void dh(uint32_t b) { r.h.dh = (byte)b; }
|
||||
#ifdef __DJGPP__
|
||||
inline void ax(ulong w) { r.x.ax = (word)w; }
|
||||
inline void bx(ulong w) { r.x.bx = (word)w; }
|
||||
inline void cx(ulong w) { r.x.cx = (word)w; }
|
||||
inline void dx(ulong w) { r.x.dx = (word)w; }
|
||||
inline void bp(ulong w) { r.x.bp = (word)w; }
|
||||
inline void si(ulong w) { r.x.si = (word)w; }
|
||||
inline void di(ulong w) { r.x.di = (word)w; }
|
||||
inline void ds(ulong w) { r.x.ds = (word)w; }
|
||||
inline void es(ulong w) { r.x.es = (word)w; }
|
||||
inline void flags(ulong w) { r.x.flags = (word)w; }
|
||||
inline void ax(uint32_t w) { r.x.ax = (word)w; }
|
||||
inline void bx(uint32_t w) { r.x.bx = (word)w; }
|
||||
inline void cx(uint32_t w) { r.x.cx = (word)w; }
|
||||
inline void dx(uint32_t w) { r.x.dx = (word)w; }
|
||||
inline void bp(uint32_t w) { r.x.bp = (word)w; }
|
||||
inline void si(uint32_t w) { r.x.si = (word)w; }
|
||||
inline void di(uint32_t w) { r.x.di = (word)w; }
|
||||
inline void ds(uint32_t w) { r.x.ds = (word)w; }
|
||||
inline void es(uint32_t w) { r.x.es = (word)w; }
|
||||
inline void flags(uint32_t w) { r.x.flags = (word)w; }
|
||||
#else
|
||||
inline void ax(ulong w) { r.w.ax = (word)w; }
|
||||
inline void bx(ulong w) { r.w.bx = (word)w; }
|
||||
inline void cx(ulong w) { r.w.cx = (word)w; }
|
||||
inline void dx(ulong w) { r.w.dx = (word)w; }
|
||||
inline void bp(ulong w) { r.w.bp = (word)w; }
|
||||
inline void si(ulong w) { r.w.si = (word)w; }
|
||||
inline void di(ulong w) { r.w.di = (word)w; }
|
||||
inline void ax(uint32_t w) { r.w.ax = (word)w; }
|
||||
inline void bx(uint32_t w) { r.w.bx = (word)w; }
|
||||
inline void cx(uint32_t w) { r.w.cx = (word)w; }
|
||||
inline void dx(uint32_t w) { r.w.dx = (word)w; }
|
||||
inline void bp(uint32_t w) { r.w.bp = (word)w; }
|
||||
inline void si(uint32_t w) { r.w.si = (word)w; }
|
||||
inline void di(uint32_t w) { r.w.di = (word)w; }
|
||||
#if defined(__BORLANDC__)
|
||||
inline void ds(ulong w) { sr.w.ds = (word)w; }
|
||||
inline void es(ulong w) { sr.w.es = (word)w; }
|
||||
inline void ds(uint32_t w) { sr.w.ds = (word)w; }
|
||||
inline void es(uint32_t w) { sr.w.es = (word)w; }
|
||||
#else
|
||||
inline void ds(ulong w) { r.w.ds = (word)w; }
|
||||
inline void es(ulong w) { r.w.es = (word)w; }
|
||||
inline void ds(uint32_t w) { r.w.ds = (word)w; }
|
||||
inline void es(uint32_t w) { r.w.es = (word)w; }
|
||||
#endif
|
||||
inline void flags(ulong w) { r.w.flags = (word)w; }
|
||||
inline void flags(uint32_t w) { r.w.flags = (word)w; }
|
||||
#endif
|
||||
|
||||
void genint(int intno);
|
||||
|
@@ -39,88 +39,88 @@
|
||||
// ------------------------------------------------------------------
|
||||
// Internal GoldED message attributes
|
||||
|
||||
const ulong GATTR_PVT = 0x00000001UL; // private
|
||||
const ulong GATTR_CRA = 0x00000002UL; // crash
|
||||
const ulong GATTR_RCV = 0x00000004UL; // received
|
||||
const ulong GATTR_SNT = 0x00000008UL; // sent
|
||||
const uint32_t GATTR_PVT = 0x00000001UL; // private
|
||||
const uint32_t GATTR_CRA = 0x00000002UL; // crash
|
||||
const uint32_t GATTR_RCV = 0x00000004UL; // received
|
||||
const uint32_t GATTR_SNT = 0x00000008UL; // sent
|
||||
|
||||
const ulong GATTR_ATT = 0x00000010UL; // file attach
|
||||
const ulong GATTR_TRS = 0x00000020UL; // transit
|
||||
const ulong GATTR_ORP = 0x00000040UL; // orphaned
|
||||
const ulong GATTR_K_S = 0x00000080UL; // kill msg when sent
|
||||
const uint32_t GATTR_ATT = 0x00000010UL; // file attach
|
||||
const uint32_t GATTR_TRS = 0x00000020UL; // transit
|
||||
const uint32_t GATTR_ORP = 0x00000040UL; // orphaned
|
||||
const uint32_t GATTR_K_S = 0x00000080UL; // kill msg when sent
|
||||
|
||||
const ulong GATTR_LOC = 0x00000100UL; // local
|
||||
const ulong GATTR_HLD = 0x00000200UL; // hold
|
||||
const ulong GATTR_RSV = 0x00000400UL; // FTS-1 reserved
|
||||
const ulong GATTR_FRQ = 0x00000800UL; // file request
|
||||
const uint32_t GATTR_LOC = 0x00000100UL; // local
|
||||
const uint32_t GATTR_HLD = 0x00000200UL; // hold
|
||||
const uint32_t GATTR_RSV = 0x00000400UL; // FTS-1 reserved
|
||||
const uint32_t GATTR_FRQ = 0x00000800UL; // file request
|
||||
|
||||
const ulong GATTR_RRQ = 0x00001000UL; // return receipt request
|
||||
const ulong GATTR_RRC = 0x00002000UL; // return receipt
|
||||
const ulong GATTR_ARQ = 0x00004000UL; // audit request
|
||||
const ulong GATTR_URQ = 0x00008000UL; // file update request
|
||||
const uint32_t GATTR_RRQ = 0x00001000UL; // return receipt request
|
||||
const uint32_t GATTR_RRC = 0x00002000UL; // return receipt
|
||||
const uint32_t GATTR_ARQ = 0x00004000UL; // audit request
|
||||
const uint32_t GATTR_URQ = 0x00008000UL; // file update request
|
||||
|
||||
const ulong GATTR_GRP = 0x00010000UL; // group msg (hudson)
|
||||
const ulong GATTR_IMM = 0x00020000UL; // immediate
|
||||
const ulong GATTR_DIR = 0x00040000UL; // direct
|
||||
const ulong GATTR_TFS = 0x00080000UL; // truncate file when sent
|
||||
const uint32_t GATTR_GRP = 0x00010000UL; // group msg (hudson)
|
||||
const uint32_t GATTR_IMM = 0x00020000UL; // immediate
|
||||
const uint32_t GATTR_DIR = 0x00040000UL; // direct
|
||||
const uint32_t GATTR_TFS = 0x00080000UL; // truncate file when sent
|
||||
|
||||
const ulong GATTR_KFS = 0x00100000UL; // kill file when sent
|
||||
const ulong GATTR_LOK = 0x00200000UL; // locked
|
||||
const ulong GATTR_A_S = 0x00400000UL; // archive msg when sent
|
||||
const ulong GATTR_ZON = 0x00800000UL; // send through zone gate
|
||||
const uint32_t GATTR_KFS = 0x00100000UL; // kill file when sent
|
||||
const uint32_t GATTR_LOK = 0x00200000UL; // locked
|
||||
const uint32_t GATTR_A_S = 0x00400000UL; // archive msg when sent
|
||||
const uint32_t GATTR_ZON = 0x00800000UL; // send through zone gate
|
||||
|
||||
const ulong GATTR_HUB = 0x01000000UL; // host- or hub route
|
||||
const ulong GATTR_XMA = 0x02000000UL; // xmail: alternate form of compressed mail attached
|
||||
const ulong GATTR_CFM = 0x04000000UL; // confirmation receipt requested
|
||||
const ulong GATTR_HIR = 0x08000000UL; // fax: hi-resolution image
|
||||
const uint32_t GATTR_HUB = 0x01000000UL; // host- or hub route
|
||||
const uint32_t GATTR_XMA = 0x02000000UL; // xmail: alternate form of compressed mail attached
|
||||
const uint32_t GATTR_CFM = 0x04000000UL; // confirmation receipt requested
|
||||
const uint32_t GATTR_HIR = 0x08000000UL; // fax: hi-resolution image
|
||||
|
||||
const ulong GATTR_COV = 0x10000000UL; // fax: cover sheet
|
||||
const ulong GATTR_SIG = 0x20000000UL; // fax: signature
|
||||
const ulong GATTR_LET = 0x40000000UL; // fax: letterhead
|
||||
const ulong GATTR_UNS = 0x80000000UL; // unsent - not scanned (internal)
|
||||
const uint32_t GATTR_COV = 0x10000000UL; // fax: cover sheet
|
||||
const uint32_t GATTR_SIG = 0x20000000UL; // fax: signature
|
||||
const uint32_t GATTR_LET = 0x40000000UL; // fax: letterhead
|
||||
const uint32_t GATTR_UNS = 0x80000000UL; // unsent - not scanned (internal)
|
||||
|
||||
const ulong GATTR_DEL = 0x00000001UL; // deleted
|
||||
const ulong GATTR_NWM = 0x00000002UL; // new message (internal)
|
||||
const ulong GATTR_ROT = 0x00000004UL; // rot-13 encoded (internal)
|
||||
const ulong GATTR_HEX = 0x00000008UL; // hexdump (internal)
|
||||
const uint32_t GATTR_DEL = 0x00000001UL; // deleted
|
||||
const uint32_t GATTR_NWM = 0x00000002UL; // new message (internal)
|
||||
const uint32_t GATTR_ROT = 0x00000004UL; // rot-13 encoded (internal)
|
||||
const uint32_t GATTR_HEX = 0x00000008UL; // hexdump (internal)
|
||||
|
||||
const ulong GATTR_UPD = 0x00000010UL; // update *.msg time stamp (internal)
|
||||
const ulong GATTR_TOU = 0x00000020UL; // to-you (internal)
|
||||
const ulong GATTR_FMU = 0x00000040UL; // from-you (internal)
|
||||
const ulong GATTR_SCN = 0x00000080UL; // scanned (squish)
|
||||
const uint32_t GATTR_UPD = 0x00000010UL; // update *.msg time stamp (internal)
|
||||
const uint32_t GATTR_TOU = 0x00000020UL; // to-you (internal)
|
||||
const uint32_t GATTR_FMU = 0x00000040UL; // from-you (internal)
|
||||
const uint32_t GATTR_SCN = 0x00000080UL; // scanned (squish)
|
||||
|
||||
const ulong GATTR_POS = 0x00000100UL; // set line position (internal)
|
||||
const ulong GATTR_R_O = 0x00000200UL; // area read-only
|
||||
const ulong GATTR_NOK = 0x00000400UL; // (not used)
|
||||
const ulong GATTR_FAX = 0x00000800UL; // file attached is a fax image
|
||||
const uint32_t GATTR_POS = 0x00000100UL; // set line position (internal)
|
||||
const uint32_t GATTR_R_O = 0x00000200UL; // area read-only
|
||||
const uint32_t GATTR_NOK = 0x00000400UL; // (not used)
|
||||
const uint32_t GATTR_FAX = 0x00000800UL; // file attached is a fax image
|
||||
|
||||
const ulong GATTR_PRN = 0x00001000UL; // message is printed (squish)
|
||||
const ulong GATTR_ANO = 0x00002000UL; // anonymous
|
||||
const ulong GATTR_UME = 0x00004000UL; // unmoved echo message (adeptxbbs)
|
||||
const ulong GATTR_UMN = 0x00008000UL; // unmoved net message (adeptxbbs)
|
||||
const uint32_t GATTR_PRN = 0x00001000UL; // message is printed (squish)
|
||||
const uint32_t GATTR_ANO = 0x00002000UL; // anonymous
|
||||
const uint32_t GATTR_UME = 0x00004000UL; // unmoved echo message (adeptxbbs)
|
||||
const uint32_t GATTR_UMN = 0x00008000UL; // unmoved net message (adeptxbbs)
|
||||
|
||||
const ulong GATTR_FSC = 0x00010000UL; // fidonet scanned (adeptxbbs)
|
||||
const ulong GATTR_GSC = 0x00020000UL; // groupmail scanned (adeptxbbs)
|
||||
const ulong GATTR_RSC = 0x00040000UL; // rfc822 scanned (adeptxbbs)
|
||||
const ulong GATTR_TRT = 0x00080000UL; // treated: soft cr's & lf's removed (adeptxbbs)
|
||||
const uint32_t GATTR_FSC = 0x00010000UL; // fidonet scanned (adeptxbbs)
|
||||
const uint32_t GATTR_GSC = 0x00020000UL; // groupmail scanned (adeptxbbs)
|
||||
const uint32_t GATTR_RSC = 0x00040000UL; // rfc822 scanned (adeptxbbs)
|
||||
const uint32_t GATTR_TRT = 0x00080000UL; // treated: soft cr's & lf's removed (adeptxbbs)
|
||||
|
||||
const ulong GATTR_LZS = 0x00100000UL; // msg is lzss compressed (adeptxbbs)
|
||||
const ulong GATTR_ARC = 0x00200000UL; // message is stored (adeptxbbs)
|
||||
const ulong GATTR_TAG = 0x00400000UL; // tagged: used by offline readers (adeptxbbs & wildcat)
|
||||
const ulong GATTR_RAB = 0x00800000UL; // receivable (wildcat)
|
||||
const uint32_t GATTR_LZS = 0x00100000UL; // msg is lzss compressed (adeptxbbs)
|
||||
const uint32_t GATTR_ARC = 0x00200000UL; // message is stored (adeptxbbs)
|
||||
const uint32_t GATTR_TAG = 0x00400000UL; // tagged: used by offline readers (adeptxbbs & wildcat)
|
||||
const uint32_t GATTR_RAB = 0x00800000UL; // receivable (wildcat)
|
||||
|
||||
const ulong GATTR_CAR = 0x01000000UL; // carboned (wildcat)
|
||||
const ulong GATTR_FWD = 0x02000000UL; // forwarded (wildcat)
|
||||
const ulong GATTR_EFL = 0x04000000UL; // echoflag (wildcat)
|
||||
const ulong GATTR_HRP = 0x08000000UL; // has replies (wildcat)
|
||||
const uint32_t GATTR_CAR = 0x01000000UL; // carboned (wildcat)
|
||||
const uint32_t GATTR_FWD = 0x02000000UL; // forwarded (wildcat)
|
||||
const uint32_t GATTR_EFL = 0x04000000UL; // echoflag (wildcat)
|
||||
const uint32_t GATTR_HRP = 0x08000000UL; // has replies (wildcat)
|
||||
|
||||
const ulong GATTR_PKD = 0x10000000UL; // Archived
|
||||
const uint32_t GATTR_PKD = 0x10000000UL; // Archived
|
||||
|
||||
class ftn_attr {
|
||||
|
||||
protected:
|
||||
|
||||
ulong attr1, attr2;
|
||||
uint32_t attr1, attr2;
|
||||
|
||||
public:
|
||||
|
||||
@@ -225,82 +225,82 @@ public:
|
||||
|
||||
// ----------------------------------------------------------------
|
||||
|
||||
void pvt(ulong x) { if(x) attr1 |= GATTR_PVT; else attr1 &= ~GATTR_PVT; }
|
||||
void cra(ulong x) { if(x) attr1 |= GATTR_CRA; else attr1 &= ~GATTR_CRA; }
|
||||
void rcv(ulong x) { if(x) attr1 |= GATTR_RCV; else attr1 &= ~GATTR_RCV; }
|
||||
void snt(ulong x) { if(x) attr1 |= GATTR_SNT; else attr1 &= ~GATTR_SNT; }
|
||||
void pvt(uint32_t x) { if(x) attr1 |= GATTR_PVT; else attr1 &= ~GATTR_PVT; }
|
||||
void cra(uint32_t x) { if(x) attr1 |= GATTR_CRA; else attr1 &= ~GATTR_CRA; }
|
||||
void rcv(uint32_t x) { if(x) attr1 |= GATTR_RCV; else attr1 &= ~GATTR_RCV; }
|
||||
void snt(uint32_t x) { if(x) attr1 |= GATTR_SNT; else attr1 &= ~GATTR_SNT; }
|
||||
|
||||
void att(ulong x) { if(x) attr1 |= GATTR_ATT; else attr1 &= ~GATTR_ATT; }
|
||||
void trs(ulong x) { if(x) attr1 |= GATTR_TRS; else attr1 &= ~GATTR_TRS; }
|
||||
void orp(ulong x) { if(x) attr1 |= GATTR_ORP; else attr1 &= ~GATTR_ORP; }
|
||||
void k_s(ulong x) { if(x) attr1 |= GATTR_K_S; else attr1 &= ~GATTR_K_S; }
|
||||
void att(uint32_t x) { if(x) attr1 |= GATTR_ATT; else attr1 &= ~GATTR_ATT; }
|
||||
void trs(uint32_t x) { if(x) attr1 |= GATTR_TRS; else attr1 &= ~GATTR_TRS; }
|
||||
void orp(uint32_t x) { if(x) attr1 |= GATTR_ORP; else attr1 &= ~GATTR_ORP; }
|
||||
void k_s(uint32_t x) { if(x) attr1 |= GATTR_K_S; else attr1 &= ~GATTR_K_S; }
|
||||
|
||||
void loc(ulong x) { if(x) attr1 |= GATTR_LOC; else attr1 &= ~GATTR_LOC; }
|
||||
void hld(ulong x) { if(x) attr1 |= GATTR_HLD; else attr1 &= ~GATTR_HLD; }
|
||||
void rsv(ulong x) { if(x) attr1 |= GATTR_RSV; else attr1 &= ~GATTR_RSV; }
|
||||
void frq(ulong x) { if(x) attr1 |= GATTR_FRQ; else attr1 &= ~GATTR_FRQ; }
|
||||
void loc(uint32_t x) { if(x) attr1 |= GATTR_LOC; else attr1 &= ~GATTR_LOC; }
|
||||
void hld(uint32_t x) { if(x) attr1 |= GATTR_HLD; else attr1 &= ~GATTR_HLD; }
|
||||
void rsv(uint32_t x) { if(x) attr1 |= GATTR_RSV; else attr1 &= ~GATTR_RSV; }
|
||||
void frq(uint32_t x) { if(x) attr1 |= GATTR_FRQ; else attr1 &= ~GATTR_FRQ; }
|
||||
|
||||
void rrq(ulong x) { if(x) attr1 |= GATTR_RRQ; else attr1 &= ~GATTR_RRQ; }
|
||||
void rrc(ulong x) { if(x) attr1 |= GATTR_RRC; else attr1 &= ~GATTR_RRC; }
|
||||
void arq(ulong x) { if(x) attr1 |= GATTR_ARQ; else attr1 &= ~GATTR_ARQ; }
|
||||
void urq(ulong x) { if(x) attr1 |= GATTR_URQ; else attr1 &= ~GATTR_URQ; }
|
||||
void rrq(uint32_t x) { if(x) attr1 |= GATTR_RRQ; else attr1 &= ~GATTR_RRQ; }
|
||||
void rrc(uint32_t x) { if(x) attr1 |= GATTR_RRC; else attr1 &= ~GATTR_RRC; }
|
||||
void arq(uint32_t x) { if(x) attr1 |= GATTR_ARQ; else attr1 &= ~GATTR_ARQ; }
|
||||
void urq(uint32_t x) { if(x) attr1 |= GATTR_URQ; else attr1 &= ~GATTR_URQ; }
|
||||
|
||||
void grp(ulong x) { if(x) attr1 |= GATTR_GRP; else attr1 &= ~GATTR_GRP; }
|
||||
void imm(ulong x) { if(x) attr1 |= GATTR_IMM; else attr1 &= ~GATTR_IMM; }
|
||||
void dir(ulong x) { if(x) attr1 |= GATTR_DIR; else attr1 &= ~GATTR_DIR; }
|
||||
void tfs(ulong x) { if(x) attr1 |= GATTR_TFS; else attr1 &= ~GATTR_TFS; }
|
||||
void grp(uint32_t x) { if(x) attr1 |= GATTR_GRP; else attr1 &= ~GATTR_GRP; }
|
||||
void imm(uint32_t x) { if(x) attr1 |= GATTR_IMM; else attr1 &= ~GATTR_IMM; }
|
||||
void dir(uint32_t x) { if(x) attr1 |= GATTR_DIR; else attr1 &= ~GATTR_DIR; }
|
||||
void tfs(uint32_t x) { if(x) attr1 |= GATTR_TFS; else attr1 &= ~GATTR_TFS; }
|
||||
|
||||
void kfs(ulong x) { if(x) attr1 |= GATTR_KFS; else attr1 &= ~GATTR_KFS; }
|
||||
void lok(ulong x) { if(x) attr1 |= GATTR_LOK; else attr1 &= ~GATTR_LOK; }
|
||||
void a_s(ulong x) { if(x) attr1 |= GATTR_A_S; else attr1 &= ~GATTR_A_S; }
|
||||
void zon(ulong x) { if(x) attr1 |= GATTR_ZON; else attr1 &= ~GATTR_ZON; }
|
||||
void kfs(uint32_t x) { if(x) attr1 |= GATTR_KFS; else attr1 &= ~GATTR_KFS; }
|
||||
void lok(uint32_t x) { if(x) attr1 |= GATTR_LOK; else attr1 &= ~GATTR_LOK; }
|
||||
void a_s(uint32_t x) { if(x) attr1 |= GATTR_A_S; else attr1 &= ~GATTR_A_S; }
|
||||
void zon(uint32_t x) { if(x) attr1 |= GATTR_ZON; else attr1 &= ~GATTR_ZON; }
|
||||
|
||||
void hub(ulong x) { if(x) attr1 |= GATTR_HUB; else attr1 &= ~GATTR_HUB; }
|
||||
void xma(ulong x) { if(x) attr1 |= GATTR_XMA; else attr1 &= ~GATTR_XMA; }
|
||||
void cfm(ulong x) { if(x) attr1 |= GATTR_CFM; else attr1 &= ~GATTR_CFM; }
|
||||
void hir(ulong x) { if(x) attr1 |= GATTR_HIR; else attr1 &= ~GATTR_HIR; }
|
||||
void hub(uint32_t x) { if(x) attr1 |= GATTR_HUB; else attr1 &= ~GATTR_HUB; }
|
||||
void xma(uint32_t x) { if(x) attr1 |= GATTR_XMA; else attr1 &= ~GATTR_XMA; }
|
||||
void cfm(uint32_t x) { if(x) attr1 |= GATTR_CFM; else attr1 &= ~GATTR_CFM; }
|
||||
void hir(uint32_t x) { if(x) attr1 |= GATTR_HIR; else attr1 &= ~GATTR_HIR; }
|
||||
|
||||
void cov(ulong x) { if(x) attr1 |= GATTR_COV; else attr1 &= ~GATTR_COV; }
|
||||
void sig(ulong x) { if(x) attr1 |= GATTR_SIG; else attr1 &= ~GATTR_SIG; }
|
||||
void let(ulong x) { if(x) attr1 |= GATTR_LET; else attr1 &= ~GATTR_LET; }
|
||||
void uns(ulong x) { if(x) attr1 |= GATTR_UNS; else attr1 &= ~GATTR_UNS; }
|
||||
void cov(uint32_t x) { if(x) attr1 |= GATTR_COV; else attr1 &= ~GATTR_COV; }
|
||||
void sig(uint32_t x) { if(x) attr1 |= GATTR_SIG; else attr1 &= ~GATTR_SIG; }
|
||||
void let(uint32_t x) { if(x) attr1 |= GATTR_LET; else attr1 &= ~GATTR_LET; }
|
||||
void uns(uint32_t x) { if(x) attr1 |= GATTR_UNS; else attr1 &= ~GATTR_UNS; }
|
||||
|
||||
void del(ulong x) { if(x) attr2 |= GATTR_DEL; else attr2 &= ~GATTR_DEL; }
|
||||
void nwm(ulong x) { if(x) attr2 |= GATTR_NWM; else attr2 &= ~GATTR_NWM; }
|
||||
void rot(ulong x) { if(x) attr2 |= GATTR_ROT; else attr2 &= ~GATTR_ROT; }
|
||||
void hex(ulong x) { if(x) attr2 |= GATTR_HEX; else attr2 &= ~GATTR_HEX; }
|
||||
void del(uint32_t x) { if(x) attr2 |= GATTR_DEL; else attr2 &= ~GATTR_DEL; }
|
||||
void nwm(uint32_t x) { if(x) attr2 |= GATTR_NWM; else attr2 &= ~GATTR_NWM; }
|
||||
void rot(uint32_t x) { if(x) attr2 |= GATTR_ROT; else attr2 &= ~GATTR_ROT; }
|
||||
void hex(uint32_t x) { if(x) attr2 |= GATTR_HEX; else attr2 &= ~GATTR_HEX; }
|
||||
|
||||
void upd(ulong x) { if(x) attr2 |= GATTR_UPD; else attr2 &= ~GATTR_UPD; }
|
||||
void tou(ulong x) { if(x) attr2 |= GATTR_TOU; else attr2 &= ~GATTR_TOU; }
|
||||
void fmu(ulong x) { if(x) attr2 |= GATTR_FMU; else attr2 &= ~GATTR_FMU; }
|
||||
void scn(ulong x) { if(x) attr2 |= GATTR_SCN; else attr2 &= ~GATTR_SCN; }
|
||||
void upd(uint32_t x) { if(x) attr2 |= GATTR_UPD; else attr2 &= ~GATTR_UPD; }
|
||||
void tou(uint32_t x) { if(x) attr2 |= GATTR_TOU; else attr2 &= ~GATTR_TOU; }
|
||||
void fmu(uint32_t x) { if(x) attr2 |= GATTR_FMU; else attr2 &= ~GATTR_FMU; }
|
||||
void scn(uint32_t x) { if(x) attr2 |= GATTR_SCN; else attr2 &= ~GATTR_SCN; }
|
||||
|
||||
void pos(ulong x) { if(x) attr2 |= GATTR_POS; else attr2 &= ~GATTR_POS; }
|
||||
void r_o(ulong x) { if(x) attr2 |= GATTR_R_O; else attr2 &= ~GATTR_R_O; }
|
||||
void nok(ulong x) { if(x) attr2 |= GATTR_NOK; else attr2 &= ~GATTR_NOK; }
|
||||
void fax(ulong x) { if(x) attr2 |= GATTR_FAX; else attr2 &= ~GATTR_FAX; }
|
||||
void pos(uint32_t x) { if(x) attr2 |= GATTR_POS; else attr2 &= ~GATTR_POS; }
|
||||
void r_o(uint32_t x) { if(x) attr2 |= GATTR_R_O; else attr2 &= ~GATTR_R_O; }
|
||||
void nok(uint32_t x) { if(x) attr2 |= GATTR_NOK; else attr2 &= ~GATTR_NOK; }
|
||||
void fax(uint32_t x) { if(x) attr2 |= GATTR_FAX; else attr2 &= ~GATTR_FAX; }
|
||||
|
||||
void prn(ulong x) { if(x) attr2 |= GATTR_PRN; else attr2 &= ~GATTR_PRN; }
|
||||
void ano(ulong x) { if(x) attr2 |= GATTR_ANO; else attr2 &= ~GATTR_ANO; }
|
||||
void ume(ulong x) { if(x) attr2 |= GATTR_UME; else attr2 &= ~GATTR_UME; }
|
||||
void umn(ulong x) { if(x) attr2 |= GATTR_UMN; else attr2 &= ~GATTR_UMN; }
|
||||
void prn(uint32_t x) { if(x) attr2 |= GATTR_PRN; else attr2 &= ~GATTR_PRN; }
|
||||
void ano(uint32_t x) { if(x) attr2 |= GATTR_ANO; else attr2 &= ~GATTR_ANO; }
|
||||
void ume(uint32_t x) { if(x) attr2 |= GATTR_UME; else attr2 &= ~GATTR_UME; }
|
||||
void umn(uint32_t x) { if(x) attr2 |= GATTR_UMN; else attr2 &= ~GATTR_UMN; }
|
||||
|
||||
void fsc(ulong x) { if(x) attr2 |= GATTR_FSC; else attr2 &= ~GATTR_FSC; }
|
||||
void gsc(ulong x) { if(x) attr2 |= GATTR_GSC; else attr2 &= ~GATTR_GSC; }
|
||||
void rsc(ulong x) { if(x) attr2 |= GATTR_RSC; else attr2 &= ~GATTR_RSC; }
|
||||
void trt(ulong x) { if(x) attr2 |= GATTR_TRT; else attr2 &= ~GATTR_TRT; }
|
||||
void fsc(uint32_t x) { if(x) attr2 |= GATTR_FSC; else attr2 &= ~GATTR_FSC; }
|
||||
void gsc(uint32_t x) { if(x) attr2 |= GATTR_GSC; else attr2 &= ~GATTR_GSC; }
|
||||
void rsc(uint32_t x) { if(x) attr2 |= GATTR_RSC; else attr2 &= ~GATTR_RSC; }
|
||||
void trt(uint32_t x) { if(x) attr2 |= GATTR_TRT; else attr2 &= ~GATTR_TRT; }
|
||||
|
||||
void lzs(ulong x) { if(x) attr2 |= GATTR_LZS; else attr2 &= ~GATTR_LZS; }
|
||||
void arc(ulong x) { if(x) attr2 |= GATTR_ARC; else attr2 &= ~GATTR_ARC; }
|
||||
void tag(ulong x) { if(x) attr2 |= GATTR_TAG; else attr2 &= ~GATTR_TAG; }
|
||||
void rab(ulong x) { if(x) attr2 |= GATTR_RAB; else attr2 &= ~GATTR_RAB; }
|
||||
void lzs(uint32_t x) { if(x) attr2 |= GATTR_LZS; else attr2 &= ~GATTR_LZS; }
|
||||
void arc(uint32_t x) { if(x) attr2 |= GATTR_ARC; else attr2 &= ~GATTR_ARC; }
|
||||
void tag(uint32_t x) { if(x) attr2 |= GATTR_TAG; else attr2 &= ~GATTR_TAG; }
|
||||
void rab(uint32_t x) { if(x) attr2 |= GATTR_RAB; else attr2 &= ~GATTR_RAB; }
|
||||
|
||||
void car(ulong x) { if(x) attr2 |= GATTR_CAR; else attr2 &= ~GATTR_CAR; }
|
||||
void fwd(ulong x) { if(x) attr2 |= GATTR_FWD; else attr2 &= ~GATTR_FWD; }
|
||||
void efl(ulong x) { if(x) attr2 |= GATTR_EFL; else attr2 &= ~GATTR_EFL; }
|
||||
void hrp(ulong x) { if(x) attr2 |= GATTR_HRP; else attr2 &= ~GATTR_HRP; }
|
||||
void car(uint32_t x) { if(x) attr2 |= GATTR_CAR; else attr2 &= ~GATTR_CAR; }
|
||||
void fwd(uint32_t x) { if(x) attr2 |= GATTR_FWD; else attr2 &= ~GATTR_FWD; }
|
||||
void efl(uint32_t x) { if(x) attr2 |= GATTR_EFL; else attr2 &= ~GATTR_EFL; }
|
||||
void hrp(uint32_t x) { if(x) attr2 |= GATTR_HRP; else attr2 &= ~GATTR_HRP; }
|
||||
|
||||
void pkd(ulong x) { if(x) attr2 |= GATTR_PKD; else attr2 &= ~GATTR_PKD; }
|
||||
void pkd(uint32_t x) { if(x) attr2 |= GATTR_PKD; else attr2 &= ~GATTR_PKD; }
|
||||
|
||||
// -------------------------------------------------------------
|
||||
|
||||
|
@@ -332,7 +332,7 @@ int str2mon(const char* ptr) {
|
||||
time32_t FTimeToTime(FTime* __ftime, struct tm* __tm) {
|
||||
|
||||
struct tm _tm;
|
||||
ulong _time = 0;
|
||||
uint32_t _time = 0;
|
||||
|
||||
if(__tm == NULL)
|
||||
__tm = &_tm;
|
||||
@@ -356,7 +356,7 @@ time32_t FTimeToTime(FTime* __ftime, struct tm* __tm) {
|
||||
time32_t b = gmktime(tp);
|
||||
_time = a + a - b;
|
||||
|
||||
if(_time == (ulong)0xFFFFFFFFL)
|
||||
if(_time == (uint32_t)0xFFFFFFFFL)
|
||||
_time = 0;
|
||||
}
|
||||
}
|
||||
@@ -447,7 +447,7 @@ time32_t FidoTimeToUnix(char* ptr) {
|
||||
time32_t b = gmktime(tp);
|
||||
return a + a - b;
|
||||
}
|
||||
return (ulong)-1;
|
||||
return (uint32_t)-1;
|
||||
}
|
||||
|
||||
|
||||
|
@@ -72,7 +72,7 @@ void GUser::inctimesposted(int) {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
ulong GUser::lastread() {
|
||||
uint32_t GUser::lastread() {
|
||||
|
||||
// No action
|
||||
return 0;
|
||||
@@ -81,7 +81,7 @@ ulong GUser::lastread() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void GUser::lastread(ulong) {
|
||||
void GUser::lastread(uint32_t) {
|
||||
|
||||
// No action
|
||||
}
|
||||
|
@@ -70,11 +70,11 @@ public:
|
||||
// ----------------------------------------------------------------
|
||||
// Virtual functions
|
||||
|
||||
virtual void founduser();
|
||||
virtual void inctimesposted(int __times);
|
||||
virtual ulong lastread();
|
||||
virtual void lastread(ulong __lastread);
|
||||
virtual void recinit(const char* __name);
|
||||
virtual void founduser();
|
||||
virtual void inctimesposted(int __times);
|
||||
virtual uint32_t lastread();
|
||||
virtual void lastread(uint32_t __lastread);
|
||||
virtual void recinit(const char* __name);
|
||||
|
||||
|
||||
// ----------------------------------------------------------------
|
||||
|
@@ -85,7 +85,7 @@ int GoldbaseUser::read() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
ulong GoldbaseUser::lastread() {
|
||||
uint32_t GoldbaseUser::lastread() {
|
||||
|
||||
seekread();
|
||||
return record->highmsgread;
|
||||
@@ -94,7 +94,7 @@ ulong GoldbaseUser::lastread() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void GoldbaseUser::lastread(ulong __lastread) {
|
||||
void GoldbaseUser::lastread(uint32_t __lastread) {
|
||||
|
||||
seekread();
|
||||
record->highmsgread = (long)__lastread;
|
||||
|
@@ -100,10 +100,10 @@ public:
|
||||
int isvalid();
|
||||
int read();
|
||||
|
||||
void inctimesposted(int __times);
|
||||
ulong lastread();
|
||||
void lastread(ulong __lastread);
|
||||
void recinit(const char* __name);
|
||||
void inctimesposted(int __times);
|
||||
uint32_t lastread();
|
||||
void lastread(uint32_t __lastread);
|
||||
void recinit(const char* __name);
|
||||
};
|
||||
|
||||
|
||||
|
@@ -85,7 +85,7 @@ int HudsonUser::read() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
ulong HudsonUser::lastread() {
|
||||
uint32_t HudsonUser::lastread() {
|
||||
|
||||
seekread();
|
||||
return record->highmsgread;
|
||||
@@ -94,7 +94,7 @@ ulong HudsonUser::lastread() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void HudsonUser::lastread(ulong __lastread) {
|
||||
void HudsonUser::lastread(uint32_t __lastread) {
|
||||
|
||||
seekread();
|
||||
record->highmsgread = (word)__lastread;
|
||||
|
@@ -101,10 +101,10 @@ public:
|
||||
int isvalid();
|
||||
int read();
|
||||
|
||||
void inctimesposted(int __times);
|
||||
ulong lastread();
|
||||
void lastread(ulong __lastread);
|
||||
void recinit(const char* __name);
|
||||
void inctimesposted(int __times);
|
||||
uint32_t lastread();
|
||||
void lastread(uint32_t __lastread);
|
||||
void recinit(const char* __name);
|
||||
};
|
||||
|
||||
|
||||
|
@@ -95,7 +95,7 @@ int RA2User::read() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
ulong RA2User::lastread() {
|
||||
uint32_t RA2User::lastread() {
|
||||
|
||||
seekread();
|
||||
return record->lastread;
|
||||
@@ -104,7 +104,7 @@ ulong RA2User::lastread() {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void RA2User::lastread(ulong __lastread) {
|
||||
void RA2User::lastread(uint32_t __lastread) {
|
||||
|
||||
seekread();
|
||||
record->lastread = (long)__lastread;
|
||||
|
@@ -142,10 +142,10 @@ public:
|
||||
int isvalid();
|
||||
int read();
|
||||
|
||||
void inctimesposted(int __times);
|
||||
ulong lastread();
|
||||
void lastread(ulong __lastread);
|
||||
void recinit(const char* __name);
|
||||
void inctimesposted(int __times);
|
||||
uint32_t lastread();
|
||||
void lastread(uint32_t __lastread);
|
||||
void recinit(const char* __name);
|
||||
|
||||
void add(const char* __name);
|
||||
};
|
||||
|
@@ -193,7 +193,7 @@ char* base64_engine::decode(char* outputbuffer, const char* inputbuffer) {
|
||||
const char* i = inputbuffer;
|
||||
|
||||
int shift = 0;
|
||||
ulong accum = 0;
|
||||
uint32_t accum = 0;
|
||||
while(*i) {
|
||||
char c = *i;
|
||||
uint value = (uint)-1;
|
||||
|
@@ -74,12 +74,12 @@ int GetYesno(const char* value) {
|
||||
// ------------------------------------------------------------------
|
||||
// Calculates a percentage
|
||||
|
||||
int Pct(ulong x, ulong y) {
|
||||
int Pct(uint32_t x, uint32_t y) {
|
||||
|
||||
if(x) {
|
||||
|
||||
ulong p = (((x-y)*100)/x);
|
||||
ulong r = (((x-y)*100)%x);
|
||||
uint32_t p = (((x-y)*100)/x);
|
||||
uint32_t r = (((x-y)*100)%x);
|
||||
|
||||
if(((r*10)/x)>4)
|
||||
p++;
|
||||
@@ -104,9 +104,9 @@ int tabstop(int column, int tabwidth) {
|
||||
// ------------------------------------------------------------------
|
||||
// Convert hex string to integer
|
||||
|
||||
ulong atoulx(const char* s) {
|
||||
uint32_t atoulx(const char* s) {
|
||||
|
||||
ulong retval = 0;
|
||||
uint32_t retval = 0;
|
||||
|
||||
s = strskip_wht(s);
|
||||
|
||||
@@ -122,7 +122,7 @@ ulong atoulx(const char* s) {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
char* ltob(char* dst, ulong value, int fill) {
|
||||
char* ltob(char* dst, uint32_t value, int fill) {
|
||||
|
||||
char* p = dst;
|
||||
|
||||
|
@@ -39,16 +39,16 @@
|
||||
// ------------------------------------------------------------------
|
||||
// Prototypes
|
||||
|
||||
ulong atoulx(const char* s);
|
||||
uint32_t atoulx(const char* s);
|
||||
|
||||
inline word atow(const char* p) { return (word)atoi(p); }
|
||||
inline int xtoi(char c) { return isdigit(c) ? (c - '0') : (toupper(c) - ('A' - 10)); }
|
||||
inline int atox(const char* s) { return (int)atoulx(s); }
|
||||
|
||||
char* ltob(char* dst, ulong value, int fill=32);
|
||||
char* ltob(char* dst, uint32_t value, int fill=32);
|
||||
|
||||
int GetYesno(const char* value);
|
||||
int Pct(ulong x, ulong y);
|
||||
int Pct(uint32_t x, uint32_t y);
|
||||
int tabstop(int col, int tabwidth);
|
||||
|
||||
char* ggetosstring();
|
||||
|
Reference in New Issue
Block a user