Namespace madness to get it to compile with gcc 3.0. Ah, 2.95 works too ;)
This commit is contained in:
@@ -71,7 +71,7 @@ void AreaList::SortAreaGroup(const char* options, int beginarea, int endarea) {
|
||||
|
||||
void RenameArea(char* echoid) {
|
||||
|
||||
vector<EchoRen>::iterator n;
|
||||
std::vector<EchoRen>::iterator n;
|
||||
for(n = CFG->arearename.begin(); n != CFG->arearename.end(); n++) {
|
||||
if(strieql(echoid, n->from.c_str())) {
|
||||
strxcpy(echoid, n->to.c_str(), sizeof(Echo));
|
||||
@@ -149,11 +149,11 @@ void AddNewArea(AreaCfg& aa) {
|
||||
void AreaList::AddNewArea(AreaCfg* aa) {
|
||||
|
||||
if(veryverbose) {
|
||||
string temp;
|
||||
cout << " fmt=" << aa->msgbase << ", eid=\"" << aa->echoid <<
|
||||
std::string temp;
|
||||
std::cout << " fmt=" << aa->msgbase << ", eid=\"" << aa->echoid <<
|
||||
"\", pth=\"" << aa->path << "\", brd=" << aa->board <<
|
||||
", gid=" << aa->groupid << ", aka=" << aa->aka.make_string(temp);
|
||||
cout << " " << aa->attr.make_string(temp) << endl;
|
||||
std::cout << " " << aa->attr.make_string(temp) << std::endl;
|
||||
}
|
||||
|
||||
Desc desc;
|
||||
@@ -321,7 +321,7 @@ void AreaList::AddNewArea(AreaCfg* aa) {
|
||||
// Add aka if not found
|
||||
if(aa->aka.net) {
|
||||
bool found = false;
|
||||
for(vector<gaka>::iterator i = CFG->aka.begin(); i != CFG->aka.end(); i++)
|
||||
for(std::vector<gaka>::iterator i = CFG->aka.begin(); i != CFG->aka.end(); i++)
|
||||
if(aa->aka == i->addr) {
|
||||
found = true;
|
||||
break;
|
||||
@@ -832,7 +832,7 @@ void AreaList::ReadEcholist(char* val) {
|
||||
tok = getkeyval;
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << file << endl;
|
||||
std::cout << "* Reading " << file << std::endl;
|
||||
|
||||
while(fgets((val=buf), sizeof(buf), fp)) {
|
||||
|
||||
@@ -1018,7 +1018,7 @@ const char* AreaCfg::setpath(const char* _path) {
|
||||
// ------------------------------------------------------------------
|
||||
// Set area origin
|
||||
|
||||
int AreaCfgBase::setorigin(string& _origin) {
|
||||
int AreaCfgBase::setorigin(std::string& _origin) {
|
||||
|
||||
if(not strblank(_origin.c_str())) {
|
||||
|
||||
@@ -1076,7 +1076,7 @@ char* MapPath(char* map, bool reverse) {
|
||||
if(reverse)
|
||||
strchg(cmap, GOLD_WRONG_SLASH_CHR, GOLD_SLASH_CHR);
|
||||
|
||||
vector< pair<string, string> >::iterator i;
|
||||
std::vector< std::pair<std::string, std::string> >::iterator i;
|
||||
for(i = CFG->mappath.begin(); i != CFG->mappath.end(); i++) {
|
||||
const char* p = reverse ? i->second.c_str() : i->first.c_str();
|
||||
const char* q = reverse ? i->first.c_str() : i->second.c_str();
|
||||
|
@@ -98,7 +98,7 @@ bool ReadGoldedCfg(int& force) {
|
||||
if(*CFG->souptosslog)
|
||||
MakePathname(CFG->souptosslog, CFG->goldpath, CFG->souptosslog);
|
||||
|
||||
vector<Tpl>::iterator t;
|
||||
std::vector<Tpl>::iterator t;
|
||||
for(t = CFG->tpl.begin(); t != CFG->tpl.end(); t++)
|
||||
MakePathname(t->file, CFG->templatepath, t->file);
|
||||
|
||||
@@ -121,7 +121,7 @@ bool ReadGoldedCfg(int& force) {
|
||||
MakePathname(CFG->semaphore.exitnow, CFG->goldpath, CFG->semaphore.exitnow);
|
||||
|
||||
if(strieql(CFG->semaphore.exportlist, AddPath(CFG->jampath, "echomail.jam"))) {
|
||||
cout << "* Warning: SEMAPHORE EXPORTLIST must not be the same as ECHOMAIL.JAM!" << endl;
|
||||
std::cout << "* Warning: SEMAPHORE EXPORTLIST must not be the same as ECHOMAIL.JAM!" << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
}
|
||||
@@ -134,7 +134,7 @@ bool ReadGoldedCfg(int& force) {
|
||||
ReadXlatTables();
|
||||
|
||||
// Free all mapfile name allocations
|
||||
vector<Map>::iterator xlt;
|
||||
std::vector<Map>::iterator xlt;
|
||||
for(xlt = CFG->xlatescset.begin(); xlt != CFG->xlatescset.end(); xlt++)
|
||||
throw_release(xlt->mapfile);
|
||||
for(xlt = CFG->xlatcharset.begin(); xlt != CFG->xlatcharset.end(); xlt++)
|
||||
@@ -214,7 +214,7 @@ void WriteGoldGed() {
|
||||
|
||||
static int EnterString(char* prompt, char* string, uint length) {
|
||||
|
||||
cout << prompt << endl << "> " << flush;
|
||||
std::cout << prompt << std::endl << "> " << std::flush;
|
||||
|
||||
*string = NUL;
|
||||
char* ptr = string;
|
||||
@@ -224,18 +224,18 @@ static int EnterString(char* prompt, char* string, uint length) {
|
||||
k = kbxget();
|
||||
if(k == Key_BS) {
|
||||
if(pos) {
|
||||
cout << "\b \b" << flush;
|
||||
std::cout << "\b \b" << std::flush;
|
||||
pos--;
|
||||
*(--ptr) = NUL;
|
||||
}
|
||||
}
|
||||
else if(k == Key_Esc) {
|
||||
cout << endl;
|
||||
std::cout << std::endl;
|
||||
*string = NUL;
|
||||
return -1;
|
||||
}
|
||||
else if(k == Key_Ent) {
|
||||
cout << endl;
|
||||
std::cout << std::endl;
|
||||
*ptr = NUL;
|
||||
break;
|
||||
}
|
||||
@@ -243,7 +243,7 @@ static int EnterString(char* prompt, char* string, uint length) {
|
||||
if(pos < length) {
|
||||
char c = (char)k;
|
||||
if(c) {
|
||||
cout << c << flush;
|
||||
std::cout << c << std::flush;
|
||||
*ptr++ = c;
|
||||
pos++;
|
||||
}
|
||||
@@ -310,10 +310,10 @@ void InstallDetect(char* path) {
|
||||
if(fexist(cmdlinecfgbak))
|
||||
remove(cmdlinecfgbak);
|
||||
rename(CFG->goldcfg, cmdlinecfgbak);
|
||||
cout << "WARNING: Existing config backed up to " << cmdlinecfgbak << "!!!" << endl;
|
||||
std::cout << "WARNING: Existing config backed up to " << cmdlinecfgbak << "!!!" << std::endl;
|
||||
}
|
||||
|
||||
cout << "Please wait while GoldED+ is detecting your software." << endl;
|
||||
std::cout << "Please wait while GoldED+ is detecting your software." << std::endl;
|
||||
|
||||
FILE* fp = fopen(CFG->goldcfg, "wt");
|
||||
if(fp) {
|
||||
@@ -342,7 +342,7 @@ void InstallDetect(char* path) {
|
||||
}
|
||||
if(fexist(AddPath(pth, idetect[i].configname))) {
|
||||
fprintf(fp, "AREAFILE %s %s\n", idetect[i].name, pth);
|
||||
cout << "Found " << idetect[i].name << (ptr ? "." : " (unreliable).") << endl;
|
||||
std::cout << "Found " << idetect[i].name << (ptr ? "." : " (unreliable).") << std::endl;
|
||||
if(streql(idetect[i].name, "Squish"))
|
||||
gotsquish = true;
|
||||
detected = true;
|
||||
@@ -356,7 +356,7 @@ void InstallDetect(char* path) {
|
||||
PathCopy(pth, ptr);
|
||||
if(fexist(AddPath(pth, "im.exe")) or fexist(AddPath(pth, "intrecho.exe"))) {
|
||||
fprintf(fp, "AREAFILE InterMail %s\n", pth);
|
||||
cout << "Found InterMail and/or InterEcho." << endl;
|
||||
std::cout << "Found InterMail and/or InterEcho." << std::endl;
|
||||
detected = true;
|
||||
}
|
||||
|
||||
@@ -371,12 +371,12 @@ void InstallDetect(char* path) {
|
||||
}
|
||||
if(fexist(AddPath(pth, "max.prm"))) {
|
||||
fprintf(fp, "AREAFILE Maximus %s\n", pth);
|
||||
cout << "Found Maximus." << endl;
|
||||
std::cout << "Found Maximus." << std::endl;
|
||||
detected = true;
|
||||
}
|
||||
if(not gotsquish and fexist(AddPath(pth, "squish.cfg"))) {
|
||||
fprintf(fp, "AREAFILE Squish %s\n", pth);
|
||||
cout << "Found Squish." << endl;
|
||||
std::cout << "Found Squish." << std::endl;
|
||||
detected = true;
|
||||
}
|
||||
|
||||
@@ -384,7 +384,7 @@ void InstallDetect(char* path) {
|
||||
strcpy(pth, CFG->areapath);
|
||||
if(fexist(AddPath(pth, "areadesc.me2"))) {
|
||||
fprintf(fp, "AREAFILE ME2 %sareadesc.me2 %sareas.bbs\n", pth, pth);
|
||||
cout << "Found ME2." << endl;
|
||||
std::cout << "Found ME2." << std::endl;
|
||||
gotareasbbs = true;
|
||||
detected = true;
|
||||
}
|
||||
@@ -394,13 +394,13 @@ void InstallDetect(char* path) {
|
||||
strcpy(pth, CFG->areapath);
|
||||
if(fexist(AddPath(pth, "areas.bbs"))) {
|
||||
fprintf(fp, "AREAFILE AreasBBS %sareas.bbs\n", pth);
|
||||
cout << "Found AREAS.BBS." << endl;
|
||||
std::cout << "Found AREAS.BBS." << std::endl;
|
||||
detected = true;
|
||||
}
|
||||
}
|
||||
|
||||
if(not detected)
|
||||
cout << "Sorry, could not find any supported software. Try another path." << endl;
|
||||
std::cout << "Sorry, could not find any supported software. Try another path." << std::endl;
|
||||
|
||||
fclose(fp);
|
||||
}
|
||||
|
@@ -694,7 +694,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
inuse++;
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << cfg << endl;
|
||||
std::cout << "* Reading " << cfg << std::endl;
|
||||
|
||||
// Assign file buffer
|
||||
setvbuf(fp, NULL, _IOFBF, 8192);
|
||||
@@ -718,7 +718,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
switch(crc) {
|
||||
case CRC_IF:
|
||||
if(in_if) {
|
||||
cout << "* " << cfgname << ": Misplaced IF at line " << line << ". IF's cannot be nested." << endl;
|
||||
std::cout << "* " << cfgname << ": Misplaced IF at line " << line << ". IF's cannot be nested." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
in_if = true;
|
||||
@@ -728,7 +728,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
case CRC_ELIF:
|
||||
case CRC_ELSEIF:
|
||||
if(not in_if or in_else) {
|
||||
cout << "* " << cfgname << ": Misplaced ELIF/ELSEIF at line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Misplaced ELIF/ELSEIF at line " << line << "." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
if(if_status)
|
||||
@@ -740,7 +740,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
break;
|
||||
case CRC_ELSE:
|
||||
if(not in_if or in_else) {
|
||||
cout << "* " << cfgname << ": Misplaced ELSE at line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Misplaced ELSE at line " << line << "." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
in_else = true;
|
||||
@@ -749,7 +749,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
break;
|
||||
case CRC_ENDIF:
|
||||
if(not in_if) {
|
||||
cout << "* " << cfgname << ": Misplaced ENDIF at line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Misplaced ENDIF at line " << line << "." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
cfgignore = false;
|
||||
@@ -764,7 +764,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
|
||||
// Tell the world what we found
|
||||
if(veryverbose)
|
||||
cout << " " << (cfgignore ? '-' : '+') << setw(4) << setfill('0') << line << setfill(' ') << ": " << key << " " << val << endl;
|
||||
std::cout << " " << (cfgignore ? '-' : '+') << std::setw(4) << std::setfill('0') << line << std::setfill(' ') << ": " << key << " " << val << std::endl;
|
||||
|
||||
// Call switch function to act on the key
|
||||
if(not cfgignore) {
|
||||
@@ -773,18 +773,18 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
case CRC_INCLUDE:
|
||||
strschg_environ(val);
|
||||
if(not quiet)
|
||||
cout << "* Including " << val << endl;
|
||||
std::cout << "* Including " << val << std::endl;
|
||||
ReadCfg(val); // NOTE! This is a recursive call!
|
||||
if(not quiet)
|
||||
cout << "* Resuming " << cfg << endl;
|
||||
std::cout << "* Resuming " << cfg << std::endl;
|
||||
break;
|
||||
case CRC_AREAFILE:
|
||||
strschg_environ(val);
|
||||
if(not quiet)
|
||||
cout << "* Handling " << key << " " << val << endl;
|
||||
std::cout << "* Handling " << key << " " << val << std::endl;
|
||||
AL.GetAreafile(val);
|
||||
if(not quiet)
|
||||
cout << "* Resuming " << cfg << endl;
|
||||
std::cout << "* Resuming " << cfg << std::endl;
|
||||
break;
|
||||
case CRC_APP:
|
||||
// Ignore 3rd party application lines
|
||||
@@ -795,7 +795,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
default:
|
||||
if(not SwitchCfg(crc, *key, val)) {
|
||||
if(not ignoreunknown) {
|
||||
cout << "* " << cfgname << ": Unknown keyword \"" << key << "\" at line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Unknown keyword \"" << key << "\" at line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
}
|
||||
@@ -836,7 +836,7 @@ int ReadCfg(const char* cfgfile, int ignoreunknown) {
|
||||
ap->set_type(AT_SOUP|AT_EMAIL|AT_NET);
|
||||
}
|
||||
|
||||
vector<MailList>::iterator z;
|
||||
std::vector<MailList>::iterator z;
|
||||
for(z = CFG->mailinglist.begin(); z != CFG->mailinglist.end(); z++) {
|
||||
Area* ap = AL.AreaEchoToPtr(z->echoid);
|
||||
if(ap)
|
||||
|
@@ -41,7 +41,7 @@ void CfgAddress(char* v) {
|
||||
if(not strblank(v)) {
|
||||
|
||||
if(veryverbose)
|
||||
cout << " CfgAddress(" << v << ")" << endl;
|
||||
std::cout << " CfgAddress(" << v << ")" << std::endl;
|
||||
|
||||
gaka aka;
|
||||
aka.domain[0] = NUL;
|
||||
@@ -349,7 +349,7 @@ void CfgArealistscan() {
|
||||
|
||||
char* _key;
|
||||
getkeyval(&_key, &val);
|
||||
AL.ListScan.Add(pair<string, string>(StripQuotes(_key), val));
|
||||
AL.ListScan.Add(std::pair<std::string, std::string>(StripQuotes(_key), val));
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
@@ -346,7 +346,7 @@ void CfgEvent() {
|
||||
|
||||
char* key;
|
||||
word x;
|
||||
vector<GEvent>::iterator n;
|
||||
std::vector<GEvent>::iterator n;
|
||||
GEvent tmp;
|
||||
|
||||
x = getkeyvalcrc(&key, &val);
|
||||
|
@@ -401,7 +401,7 @@ void CfgMailtoss() {
|
||||
void CfgMappath() {
|
||||
|
||||
char* key;
|
||||
pair<string, string> mapentry;
|
||||
std::pair<std::string, std::string> mapentry;
|
||||
|
||||
getkeyval(&key, &val);
|
||||
|
||||
|
@@ -363,7 +363,7 @@ void CfgUsername() {
|
||||
strxcpy(tmp.name, strbtrim(val), sizeof(Name));
|
||||
|
||||
// Check if we have it already
|
||||
vector<Node>::iterator u;
|
||||
std::vector<Node>::iterator u;
|
||||
for(u = CFG->username.begin(); u != CFG->username.end(); u++)
|
||||
if(strieql(tmp.name, u->name))
|
||||
return;
|
||||
@@ -514,7 +514,7 @@ void CfgXlatexport() {
|
||||
else
|
||||
strcpy(CFG->xlatexport, buf);
|
||||
if(CFG->usecharset and (strieql(buf, "IBMPC") or strieql(buf, "+7_FIDO"))) {
|
||||
cout << "* Warning: Charset " << buf << " is obsolte. Consider using CPxxx form." << endl;
|
||||
std::cout << "* Warning: Charset " << buf << " is obsolete. Consider using CPxxx form." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
}
|
||||
@@ -537,7 +537,7 @@ void CfgXlatlocalset() {
|
||||
|
||||
strupr(strxcpy(CFG->xlatlocalset, val, sizeof(CFG->xlatlocalset)));
|
||||
if(strieql(CFG->xlatlocalset, "IBMPC") or strieql(CFG->xlatlocalset, "+7_FIDO")) {
|
||||
cout << "* Warning: Charset " << CFG->xlatlocalset << " is obsolte. Cosider using CPxxx form." << endl;
|
||||
std::cout << "* Warning: Charset " << CFG->xlatlocalset << " is obsolete. Consider using CPxxx form." << std::endl;
|
||||
cfgerrors++;
|
||||
}
|
||||
}
|
||||
|
@@ -882,7 +882,7 @@ void KeyCmdAdd(gkey keycmd, gkey keyval, int keytype) {
|
||||
if(keyval <= 0xFF)
|
||||
keyval |= (gkey)(scancode(keyval) << 8);
|
||||
|
||||
list<CmdKey>::iterator tmp = CFG->cmdkey.begin();
|
||||
std::list<CmdKey>::iterator tmp = CFG->cmdkey.begin();
|
||||
if(CFG->switches.get(keybdefaults)) {
|
||||
while(tmp != CFG->cmdkey.end()) {
|
||||
if(tmp->type == keytype) {
|
||||
@@ -975,7 +975,7 @@ int ReadKeysCfg(int force) {
|
||||
cfgname = cfgname ? cfgname+1 : cfg;
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << cfg << endl;
|
||||
std::cout << "* Reading " << cfg << std::endl;
|
||||
|
||||
CFG->macro.clear();
|
||||
CFG->cmdkey.clear();
|
||||
@@ -993,7 +993,7 @@ int ReadKeysCfg(int force) {
|
||||
keycmd = SwitchKeyDefs(strCrc16(strupr(ptr2)), &keytype);
|
||||
if(keycmd) {
|
||||
if(keytype) {
|
||||
cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
continue;
|
||||
@@ -1009,7 +1009,7 @@ int ReadKeysCfg(int force) {
|
||||
else if(strlen(ptr2) == 1)
|
||||
keyval = (gkey)tolower(*ptr2); // Always convert to lowercase internally
|
||||
else {
|
||||
cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
continue;
|
||||
@@ -1046,7 +1046,7 @@ int ReadKeysCfg(int force) {
|
||||
tmp2.buf[n++] = (gkey)keycmd;
|
||||
}
|
||||
else {
|
||||
cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
continue;
|
||||
@@ -1061,7 +1061,7 @@ int ReadKeysCfg(int force) {
|
||||
CFG->macro.push_back(tmp2);
|
||||
|
||||
// delete overlayed (non-macro) key definition
|
||||
list<CmdKey>::iterator tmp = CFG->cmdkey.begin();
|
||||
std::list<CmdKey>::iterator tmp = CFG->cmdkey.begin();
|
||||
while(tmp != CFG->cmdkey.end()) {
|
||||
if(tmp->type == keytype) {
|
||||
if(tmp->key == keyval) {
|
||||
@@ -1076,14 +1076,14 @@ int ReadKeysCfg(int force) {
|
||||
else if(keytype)
|
||||
KeyCmdAdd(keycmd, keyval, keytype);
|
||||
else {
|
||||
cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
else {
|
||||
cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << endl;
|
||||
std::cout << "* " << cfgname << ": Invalid key \"" << ptr2 << "\" in line " << line << "." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
continue;
|
||||
@@ -1100,7 +1100,7 @@ int ReadKeysCfg(int force) {
|
||||
CFG->cmdkey.sort(CmdKeyCmp);
|
||||
|
||||
// Count keys
|
||||
list<CmdKey>::iterator ck = CFG->cmdkey.begin();
|
||||
std::list<CmdKey>::iterator ck = CFG->cmdkey.begin();
|
||||
while(ck != CFG->cmdkey.end()) {
|
||||
switch(ck->type) {
|
||||
case KT_A: AreaKeys++; if(AreaKeys == 1) AreaKey = ck; break;
|
||||
@@ -1117,7 +1117,7 @@ int ReadKeysCfg(int force) {
|
||||
}
|
||||
|
||||
// Assign global macros
|
||||
vector<Macro>::iterator k;
|
||||
std::vector<Macro>::iterator k;
|
||||
for(k=CFG->macro.begin(), n=0; k != CFG->macro.end(); k++, n++) {
|
||||
if(k->type == 0) {
|
||||
if(k->key == KK_Auto) {
|
||||
|
@@ -671,7 +671,7 @@ bool ReadLangCfg(int force) {
|
||||
setvbuf(fpi, NULL, _IOFBF, 8192);
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << cfgname << endl;
|
||||
std::cout << "* Reading " << cfgname << std::endl;
|
||||
|
||||
cfgname = CleanFilename(cfgname);
|
||||
|
||||
@@ -691,7 +691,7 @@ bool ReadLangCfg(int force) {
|
||||
}
|
||||
if(SwitchLanguage(strCrc16(strupr(ptr)), str)) {
|
||||
if(cmdlineoldkeyw == false) {
|
||||
cout << "* " << cfgname << " line " << line << ": \"" << ptr << "\" is obsolete or unknown." << endl;
|
||||
std::cout << "* " << cfgname << " line " << line << ": \"" << ptr << "\" is obsolete or unknown." << std::endl;
|
||||
SayBibi();
|
||||
cfgerrors++;
|
||||
}
|
||||
|
@@ -52,7 +52,7 @@ int ReadHelpCfg(int force) {
|
||||
CFG->helpcfg.ft = GetFiletime(AddPath(CFG->goldpath, CFG->helpcfg.fn));
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << AddPath(CFG->goldpath, CFG->helpcfg.fn) << endl;
|
||||
std::cout << "* Reading " << AddPath(CFG->goldpath, CFG->helpcfg.fn) << std::endl;
|
||||
|
||||
setvbuf(ofp, NULL, _IOFBF, 8192);
|
||||
|
||||
@@ -603,7 +603,7 @@ void ReadXlatTables() {
|
||||
if(ofp) {
|
||||
|
||||
// Compile CHARSET tables
|
||||
vector<Map>::iterator xlt;
|
||||
std::vector<Map>::iterator xlt;
|
||||
for(xlt = CFG->xlatcharset.begin(); xlt != CFG->xlatcharset.end(); xlt++) {
|
||||
|
||||
// Assign table defaults
|
||||
@@ -617,7 +617,7 @@ void ReadXlatTables() {
|
||||
if(ifp) {
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << buf << endl;
|
||||
std::cout << "* Reading " << buf << std::endl;
|
||||
|
||||
// Read the definition file
|
||||
line = 1;
|
||||
@@ -699,7 +699,7 @@ void ReadXlatTables() {
|
||||
fclose(ifp);
|
||||
}
|
||||
else
|
||||
cout << "* XLAT table " << buf << " could not be opened." << endl;
|
||||
std::cout << "* XLAT table " << buf << " could not be opened." << std::endl;
|
||||
|
||||
fwrite(&ChsTable, sizeof(Chs), 1, ofp);
|
||||
}
|
||||
@@ -714,7 +714,7 @@ void ReadXlatTables() {
|
||||
if(ifp) {
|
||||
|
||||
if(not quiet)
|
||||
cout << "* Reading " << buf << endl;
|
||||
std::cout << "* Reading " << buf << std::endl;
|
||||
|
||||
// Read the definition file
|
||||
line = 1;
|
||||
@@ -778,7 +778,7 @@ void ReadXlatTables() {
|
||||
fclose(ifp);
|
||||
}
|
||||
else
|
||||
cout << "* XLAT table " << buf << " could not be opened." << endl;
|
||||
std::cout << "* XLAT table " << buf << " could not be opened." << std::endl;
|
||||
|
||||
fwrite(&EscTable, sizeof(Esc), 1, ofp);
|
||||
}
|
||||
|
@@ -369,8 +369,8 @@ struct Tpl {
|
||||
|
||||
class EchoRen {
|
||||
public:
|
||||
string from;
|
||||
string to;
|
||||
std::string from;
|
||||
std::string to;
|
||||
EchoRen() {}
|
||||
EchoRen(const char *_from, const char *_to) { from = _from; to = _to; }
|
||||
~EchoRen() {}
|
||||
@@ -914,7 +914,7 @@ struct Ezycom {
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
struct Invalidate {
|
||||
pair<string, string> origin, seenby, tearline, cc, xc, xp;
|
||||
std::pair<std::string, std::string> origin, seenby, tearline, cc, xc, xp;
|
||||
};
|
||||
|
||||
|
||||
|
@@ -196,7 +196,7 @@ int DoCarboncopy(GMsg* msg, GMsg** carbon) {
|
||||
newline = newline->next;
|
||||
} while(newline != NULL);
|
||||
|
||||
string temp;
|
||||
std::string temp;
|
||||
// Fix the CC list in the message
|
||||
if(cc and ccline) {
|
||||
switch(CFG->carboncopylist) {
|
||||
@@ -235,7 +235,7 @@ int DoCarboncopy(GMsg* msg, GMsg** carbon) {
|
||||
case CC_NAMES:
|
||||
// Expand in line
|
||||
{
|
||||
string hline = "";
|
||||
std::string hline = "";
|
||||
int line_items = 0;
|
||||
|
||||
if(A == AA) {
|
||||
@@ -285,7 +285,7 @@ int DoCarboncopy(GMsg* msg, GMsg** carbon) {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
static bool AddXCAreas(const char* mask, bool attr, vector<int> &postareas, vector<bool> &postareas_attrs, int local_xps) {
|
||||
static bool AddXCAreas(const char* mask, bool attr, std::vector<int> &postareas, std::vector<bool> &postareas_attrs, int local_xps) {
|
||||
|
||||
bool rv = false;
|
||||
|
||||
@@ -313,7 +313,7 @@ static bool AddXCAreas(const char* mask, bool attr, vector<int> &postareas, vect
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void DoCrosspost(GMsg* msg, vector<int> &postareas) {
|
||||
void DoCrosspost(GMsg* msg, std::vector<int> &postareas) {
|
||||
|
||||
if(CFG->crosspost == NO)
|
||||
return;
|
||||
@@ -325,7 +325,7 @@ void DoCrosspost(GMsg* msg, vector<int> &postareas) {
|
||||
int margintext;
|
||||
bool xphide;
|
||||
int local_xps = postareas.size();
|
||||
vector<bool> postareas_attrs(local_xps);
|
||||
std::vector<bool> postareas_attrs(local_xps);
|
||||
bool hideoriginal = false;
|
||||
|
||||
// Insert empty line at the top first for practical purposes
|
||||
@@ -425,7 +425,7 @@ void DoCrosspost(GMsg* msg, vector<int> &postareas) {
|
||||
xcline = AddLine(xcline, buf);
|
||||
}
|
||||
|
||||
string hline = "";
|
||||
std::string hline = "";
|
||||
int line_items = 0;
|
||||
|
||||
for(int i=local_xps; i < postareas.size(); i++) {
|
||||
|
@@ -132,16 +132,16 @@ public:
|
||||
int cfgeditquotemargin;
|
||||
int cfgquotemargin;
|
||||
|
||||
list<CmdKey> cmdkey;
|
||||
vector<Macro> macro;
|
||||
std::list<CmdKey> cmdkey;
|
||||
std::vector<Macro> macro;
|
||||
|
||||
int addressbookadd;
|
||||
int addresslookupfirst;
|
||||
vector<AddrMacro> addressmacro;
|
||||
std::vector<AddrMacro> addressmacro;
|
||||
Path adeptxbbspath;
|
||||
int adeptxbbsuserno;
|
||||
vector<gaka> aka;
|
||||
vector<AkaMatchG> akamatch;
|
||||
std::vector<gaka> aka;
|
||||
std::vector<AkaMatchG> akamatch;
|
||||
int areaautoid;
|
||||
Echo areacfmreplyto;
|
||||
bool areacopydirect;
|
||||
@@ -165,7 +165,7 @@ public:
|
||||
gstrarray areapmscanexcl;
|
||||
gstrarray areapmscanincl;
|
||||
int areareadonly;
|
||||
vector<EchoRen> arearename;
|
||||
std::vector<EchoRen> arearename;
|
||||
bool areareplydirect;
|
||||
Echo areareplyto;
|
||||
gstrarray areascan;
|
||||
@@ -209,19 +209,19 @@ public:
|
||||
int dispmsgsize;
|
||||
uint disptabsize; // tabsize;
|
||||
bool encodeemailheaders;
|
||||
vector<GEvent> event;
|
||||
std::vector<GEvent> event;
|
||||
int externoptions;
|
||||
vector<ExtUtil> externutil;
|
||||
std::vector<ExtUtil> externutil;
|
||||
Ezycom ezycom;
|
||||
int ezycomuserno;
|
||||
Path fidolastread; // lastread;
|
||||
int fidomsgtype;
|
||||
Path fidouserlist;
|
||||
int fidouserno; // lastreaduser;
|
||||
vector<FileAlias> filealias;
|
||||
std::vector<FileAlias> filealias;
|
||||
bool forcetemplate;
|
||||
gstrarray frqext;
|
||||
vector<FrqNodeMap> frqnodemap;
|
||||
std::vector<FrqNodeMap> frqnodemap;
|
||||
int frqoptions;
|
||||
bool gedhandshake;
|
||||
Path goldbasepath;
|
||||
@@ -255,8 +255,8 @@ public:
|
||||
Path loadlanguage;
|
||||
Path logfile; // goldedlog;
|
||||
int logformat;
|
||||
vector<MailList> mailinglist;
|
||||
vector< pair<string, string> > mappath;
|
||||
std::vector<MailList> mailinglist;
|
||||
std::vector< std::pair<std::string, std::string> > mappath;
|
||||
int menumarked;
|
||||
int msglistdate;
|
||||
bool msglistfast;
|
||||
@@ -329,21 +329,21 @@ public:
|
||||
char tasktitle[60];
|
||||
Tear tearline;
|
||||
bool titlestatus;
|
||||
vector<Tpl> tpl;
|
||||
std::vector<Tpl> tpl;
|
||||
int tplno;
|
||||
bool templatematch;
|
||||
Path templatepath;
|
||||
Path temppath;
|
||||
int timeout;
|
||||
int twitmode; // showtwits;
|
||||
vector<Node> twitname;
|
||||
std::vector<Node> twitname;
|
||||
gstrarray twitsubj;
|
||||
bool usecharset;
|
||||
int usefwd;
|
||||
bool useintl;
|
||||
bool usepid;
|
||||
Path userlistfile; // goldedlst;
|
||||
vector<Node> username;
|
||||
std::vector<Node> username;
|
||||
int usernameno;
|
||||
bool usestylies;
|
||||
bool usetzutc;
|
||||
@@ -353,9 +353,9 @@ public:
|
||||
bool viewquote;
|
||||
Name whoto;
|
||||
int wildcatuserno;
|
||||
string wtpl;
|
||||
vector<Map> xlatcharset;
|
||||
vector<Map> xlatescset;
|
||||
std::string wtpl;
|
||||
std::vector<Map> xlatcharset;
|
||||
std::vector<Map> xlatescset;
|
||||
char xlatexport[17]; // exportcharset[17];
|
||||
char xlatimport[17]; // localcharset[17];
|
||||
char xlatlocalset[17];
|
||||
|
@@ -579,7 +579,7 @@ void DoTearorig(int mode, GMsg* msg) {
|
||||
char* ptr;
|
||||
Line* line = msg->lin;
|
||||
Line* newline;
|
||||
string origin;
|
||||
std::string origin;
|
||||
|
||||
origin = AA->Origin();
|
||||
|
||||
|
@@ -79,7 +79,7 @@ void SaveLines(int mode, const char* savefile, GMsg* msg, int margin, bool clip)
|
||||
while(line) {
|
||||
uint lineisctrl = line->type & (GLINE_TEAR|GLINE_ORIG|GLINE_KLUDGE);
|
||||
if(not ((mode == MODE_SAVENOCTRL) and lineisctrl)) {
|
||||
string::iterator p = line->txt.begin();
|
||||
std::string::iterator p = line->txt.begin();
|
||||
while(p != line->txt.end()) {
|
||||
if(mode == MODE_WRITE) {
|
||||
// Replace control codes, except the ANSI escape code
|
||||
|
@@ -175,11 +175,11 @@ void Cleanup(void) {
|
||||
|
||||
int smax = MinV((int)GLOG_STORELINES, LOG.storelines);
|
||||
for(int s=0; s<smax; s++)
|
||||
cout << LOG.storeline[s] << endl;
|
||||
std::cout << LOG.storeline[s] << std::endl;
|
||||
|
||||
if(CFG) {
|
||||
if(LOG.storelines > GLOG_STORELINES)
|
||||
cout << "(See also " << CFG->logfile << ")" << endl;
|
||||
std::cout << "(See also " << CFG->logfile << ")" << std::endl;
|
||||
if(errorlevel > EXIT_NONAME)
|
||||
MakeNoise(SND_S_O_S);
|
||||
|
||||
|
@@ -711,7 +711,7 @@ Line* IEclass::wrapit(Line** __currline, uint* __curr_col, uint* __curr_row, boo
|
||||
// The line is hard-terminated.
|
||||
|
||||
// Copy the quote string, if any, to the new line first
|
||||
string _wrapbuf = _quotebuf;
|
||||
std::string _wrapbuf = _quotebuf;
|
||||
|
||||
// Copy/append the wrapped part to the new line
|
||||
_wrapbuf += _thisline->txt.substr(_wrappos);
|
||||
@@ -755,7 +755,7 @@ Line* IEclass::wrapit(Line** __currline, uint* __curr_col, uint* __curr_row, boo
|
||||
Line* _nextline = _thisline->next;
|
||||
|
||||
// Copy the quote string, if any, to the new line first
|
||||
string _wrapbuf = _quotebuf;
|
||||
std::string _wrapbuf = _quotebuf;
|
||||
|
||||
// Copy/append the wrapped part to the new line
|
||||
_wrapbuf += _thisline->txt.substr(_wrappos);
|
||||
@@ -1208,7 +1208,7 @@ void IEclass::Newline() {
|
||||
int _splitpos = col;
|
||||
|
||||
// Buffer for the second part of the split line
|
||||
string _splitbuf;
|
||||
std::string _splitbuf;
|
||||
|
||||
// If the split line was quoted, get the quotestring
|
||||
// But do not get it if the cursor points to a linefeed or is
|
||||
@@ -2590,7 +2590,7 @@ void UndoStack::PlayItem() {
|
||||
|
||||
case EDIT_UNDO_TEXT: {
|
||||
text_item* text_data = last_item->data.text_ptr;
|
||||
string *txt = &currline->txt;
|
||||
std::string *txt = &currline->txt;
|
||||
switch(undo_action) {
|
||||
case EDIT_UNDO_DEL_TEXT:
|
||||
txt->insert(text_data->col, text_data->text, text_data->len);
|
||||
|
@@ -908,7 +908,7 @@ void IEclass::editimport(Line* __line, char* __filename, bool imptxt) {
|
||||
ImportMode = MenuImportTxt.Run();
|
||||
}
|
||||
|
||||
string filenamebuf;
|
||||
std::string filenamebuf;
|
||||
Path tmpfile;
|
||||
bool isPipe = NO;
|
||||
bool fileselected = false;
|
||||
|
@@ -83,7 +83,7 @@ void IEclass::Buf2Clip() {
|
||||
|
||||
gclipbrd clipbrd;
|
||||
Line *_bufline;
|
||||
string clipdata;
|
||||
std::string clipdata;
|
||||
|
||||
for(_bufline = Edit__pastebuf; _bufline; _bufline = _bufline->next)
|
||||
if(not _bufline->txt.empty()) {
|
||||
|
@@ -967,7 +967,7 @@ void FileRequest(GMsg* msg) {
|
||||
AA->Open();
|
||||
if(CFG->frqoptions & FREQ_FAST)
|
||||
savedirect = true;
|
||||
vector<FrqNodeMap>::iterator fnm;
|
||||
std::vector<FrqNodeMap>::iterator fnm;
|
||||
for(fnm = CFG->frqnodemap.begin(); fnm != CFG->frqnodemap.end(); fnm++) {
|
||||
if(fnm->from.equals(msg->orig)) {
|
||||
msg->orig = fnm->to;
|
||||
|
@@ -58,7 +58,7 @@ int EditKeys = 0;
|
||||
int FileKeys = 0;
|
||||
int AddressbookKeys = 0;
|
||||
int HeaderKeys = 0;
|
||||
list<CmdKey>::iterator AreaKey, ReadKey, ListKey, NodeKey, EditKey, FileKey, AddressbookKey, HeaderKey;
|
||||
std::list<CmdKey>::iterator AreaKey, ReadKey, ListKey, NodeKey, EditKey, FileKey, AddressbookKey, HeaderKey;
|
||||
|
||||
int inforow = 18;
|
||||
|
||||
@@ -263,7 +263,7 @@ bool inline samekey(gkey key1, gkey key2) {
|
||||
|
||||
int IsMacro(gkey key, int type) {
|
||||
|
||||
vector<Macro>::iterator m = CFG->macro.begin();
|
||||
std::vector<Macro>::iterator m = CFG->macro.begin();
|
||||
while(m != CFG->macro.end()) {
|
||||
if(((key == m->key) or samekey(key, m->key)) and (type == m->type))
|
||||
return true;
|
||||
@@ -278,10 +278,10 @@ int IsMacro(gkey key, int type) {
|
||||
|
||||
int PlayMacro(gkey key, int type) {
|
||||
|
||||
vector<Macro>::iterator m = CFG->macro.begin();
|
||||
std::vector<Macro>::iterator m = CFG->macro.begin();
|
||||
while(m != CFG->macro.end()) {
|
||||
if(((key == m->key) or samekey(key, m->key)) and (type == m->type)) {
|
||||
RunMacro(m);
|
||||
RunMacro(&(*m));
|
||||
return true;
|
||||
}
|
||||
m++;
|
||||
|
@@ -101,7 +101,7 @@ extern int m_titlepos;
|
||||
extern int m_titleattr;
|
||||
|
||||
extern int AreaKeys, ReadKeys, ListKeys, NodeKeys, EditKeys, FileKeys, AddressbookKeys, HeaderKeys;
|
||||
extern list<CmdKey>::iterator AreaKey, ReadKey, ListKey, NodeKey, EditKey, FileKey, AddressbookKey, HeaderKey;
|
||||
extern std::list<CmdKey>::iterator AreaKey, ReadKey, ListKey, NodeKey, EditKey, FileKey, AddressbookKey, HeaderKey;
|
||||
|
||||
extern int inforow;
|
||||
|
||||
|
@@ -138,7 +138,7 @@ bool set_to_address(GMsg* msg, gsetaddr* toname, gsetaddr* toaddr, gsetaddr* fro
|
||||
strcpy(buf, ptr);
|
||||
|
||||
if(not CFG->addressmacro.empty()) {
|
||||
vector<AddrMacro>::iterator n;
|
||||
std::vector<AddrMacro>::iterator n;
|
||||
for(n=CFG->addressmacro.begin(); n != CFG->addressmacro.end(); n++) {
|
||||
if(strieql(buf, n->macro)) {
|
||||
ptr = strcpy(buf1, n->name);
|
||||
@@ -299,7 +299,7 @@ bool GMsgHeaderEdit::validate() {
|
||||
field* ftoaddr = get_field(id_to_addr);
|
||||
field* fsubj = get_field(id_subject);
|
||||
gsetaddr toname, toaddr, fromaddr, subj;
|
||||
string orig_toname;
|
||||
std::string orig_toname;
|
||||
|
||||
orig_toname = msg->to;
|
||||
toname.buf = current->buf; toname.update = false;
|
||||
@@ -307,7 +307,7 @@ bool GMsgHeaderEdit::validate() {
|
||||
fromaddr.buf = ffromaddr->buf; fromaddr.update = false;
|
||||
subj.buf = fsubj->buf; subj.update = false;
|
||||
|
||||
string iaddr(msg->iaddr), realto(msg->realto);
|
||||
std::string iaddr(msg->iaddr), realto(msg->realto);
|
||||
|
||||
bool res = set_to_address(msg, &toname, &toaddr, &fromaddr, &subj, 0, LNG->SelectDestNode, lookup);
|
||||
|
||||
@@ -351,8 +351,8 @@ int EditHeaderinfo(int mode, GMsgHeaderView &view, bool doedithdr) {
|
||||
GMsgHeaderEdit hedit(view);
|
||||
GMsg *msg = view.msg;
|
||||
|
||||
string from_name, to_name, subject;
|
||||
string from_addr, to_addr, orig_from_addr;
|
||||
std::string from_name, to_name, subject;
|
||||
std::string from_addr, to_addr, orig_from_addr;
|
||||
|
||||
from_name = msg->By();
|
||||
if(AA->isinternet()) {
|
||||
@@ -558,9 +558,9 @@ int EditHeaderinfo(int mode, GMsgHeaderView &view, bool doedithdr) {
|
||||
}
|
||||
|
||||
// Try to match akas with the dest address, but only if the orig address was NOT changed
|
||||
vector<gaka>::iterator i;
|
||||
std::vector<gaka>::iterator i;
|
||||
for(i = CFG->aka.begin(); i != CFG->aka.end(); i++) {
|
||||
if(memcmp(&msg->orig, i, sizeof(Addr)) == 0)
|
||||
if(memcmp(&msg->orig, &(*i), sizeof(Addr)) == 0)
|
||||
break; // Found one of our own akas.
|
||||
}
|
||||
|
||||
|
@@ -45,7 +45,7 @@ extern int __gftrk_statusline;
|
||||
extern bool gmem_check_overrun;
|
||||
#endif
|
||||
|
||||
static string keybuf;
|
||||
static std::string keybuf;
|
||||
|
||||
static Path cmdlinecfg = "";
|
||||
bool cmdlinedebughg = false;
|
||||
@@ -81,7 +81,7 @@ static void InitCmdline(char* val) {
|
||||
if(*val)
|
||||
strcpy(cmdlinecfg, val);
|
||||
else
|
||||
cout << "Warning: configuration filename missed for -C option, ignored." << endl;
|
||||
std::cout << "Warning: configuration filename missed for -C option, ignored." << std::endl;
|
||||
break;
|
||||
case 'D':
|
||||
cmdlineoldkeyw = (*val == '-') ? true : false;
|
||||
@@ -149,7 +149,7 @@ static void InitCmdline(char* val) {
|
||||
case 'Z':
|
||||
gftrk_set_max = atoi(val);
|
||||
if(gftrk_set_max == 0) {
|
||||
cout << "Warning: Invalid parameter for -Z option, fixed." << endl;
|
||||
std::cout << "Warning: Invalid parameter for -Z option, fixed." << std::endl;
|
||||
gftrk_set_max = 1;
|
||||
}
|
||||
break;
|
||||
@@ -206,7 +206,7 @@ static void ReadEscsets() {
|
||||
|
||||
FILE* fp;
|
||||
|
||||
vector<Map>::iterator x;
|
||||
std::vector<Map>::iterator x;
|
||||
int n;
|
||||
for(n = 0, x = CFG->xlatescset.begin(); x != CFG->xlatescset.end(); x++, n++) {
|
||||
if(strieql(x->imp, "Composed")) {
|
||||
@@ -487,7 +487,7 @@ void Initialize(int argc, char* argv[]) {
|
||||
char* ptr2;
|
||||
bool dbedit = false;
|
||||
bool found = false, compiled;
|
||||
string truepathtmp;
|
||||
std::string truepathtmp;
|
||||
|
||||
throw_init();
|
||||
#if defined(GTHROW_LOG)
|
||||
@@ -507,7 +507,7 @@ void Initialize(int argc, char* argv[]) {
|
||||
srand((unsigned)time(NULL));
|
||||
|
||||
// Display startup banner
|
||||
cout << __gver_longpid__ << " " << __gver_ver__ << endl;
|
||||
std::cout << __gver_longpid__ << " " << __gver_ver__ << std::endl;
|
||||
|
||||
// Check environment commandline
|
||||
ptr = getenv("GEDCMD");
|
||||
@@ -548,33 +548,33 @@ void Initialize(int argc, char* argv[]) {
|
||||
|
||||
// Print commandline help and exit if requested
|
||||
if(cmdlinehelp) {
|
||||
cout <<
|
||||
"Copyright (C) 1990-2000 Odinn Sorensen, Alexander Aganichev, Jacobo Tarrio and" << endl <<
|
||||
" others" << endl <<
|
||||
"-------------------------------------------------------------------------------" << endl <<
|
||||
endl <<
|
||||
"Invocation: " << argv[0] << " [-options] [keystacking]" << endl <<
|
||||
endl <<
|
||||
"-C<configfile> Use a different configuration file." << endl <<
|
||||
"-D Disable old obsolete configuration keywords." << endl <<
|
||||
"-E<echoid> Start directly in the specified mail area." << endl <<
|
||||
"-EXPORTSOUP Export SOUP packets during startup." << endl <<
|
||||
"-F or -FF Force recompile of most (or all with -FF) configuration files." << endl <<
|
||||
"-INSTALL[=path] Start the quick install procedure. Look in path, if given." << endl <<
|
||||
"-IMPORTSOUP Import SOUP packets during startup." << endl <<
|
||||
"-M Mute sounds. Disables all noises in GoldED+." << endl <<
|
||||
"-N Disable share-compatible file opens during startup." << endl <<
|
||||
"-NOSCAN Temporarily disable area scan during startup." << endl <<
|
||||
std::cout <<
|
||||
"Copyright (C) 1990-2000 Odinn Sorensen, Alexander Aganichev, Jacobo Tarrio and" << std::endl <<
|
||||
" others" << std::endl <<
|
||||
"-------------------------------------------------------------------------------" << std::endl <<
|
||||
std::endl <<
|
||||
"Invocation: " << argv[0] << " [-options] [keystacking]" << std::endl <<
|
||||
std::endl <<
|
||||
"-C<configfile> Use a different configuration file." << std::endl <<
|
||||
"-D Disable old obsolete configuration keywords." << std::endl <<
|
||||
"-E<echoid> Start directly in the specified mail area." << std::endl <<
|
||||
"-EXPORTSOUP Export SOUP packets during startup." << std::endl <<
|
||||
"-F or -FF Force recompile of most (or all with -FF) configuration files." << std::endl <<
|
||||
"-INSTALL[=path] Start the quick install procedure. Look in path, if given." << std::endl <<
|
||||
"-IMPORTSOUP Import SOUP packets during startup." << std::endl <<
|
||||
"-M Mute sounds. Disables all noises in GoldED+." << std::endl <<
|
||||
"-N Disable share-compatible file opens during startup." << std::endl <<
|
||||
"-NOSCAN Temporarily disable area scan during startup." << std::endl <<
|
||||
#if defined(GUTLOS_FUNCS) && !defined(__MSDOS__)
|
||||
"-P Increase program priority to run faster." << endl <<
|
||||
"-P Increase program priority to run faster." << std::endl <<
|
||||
#endif
|
||||
"-S<sortspec> Sorts all mail areas according to the sort specs." << endl <<
|
||||
"-T<seconds> Set a timeout value. GoldED+ will auto-exit after timeout." << endl <<
|
||||
"-V or -VV Verbose or Very verbose (-VV) config compile. Use -VV to debug." << endl <<
|
||||
"-W Write a GOLDAREA.INC file with AREADEF's of all mail areas." << endl <<
|
||||
"-X, -Y, -Z Reserved for debugging purposes." << endl <<
|
||||
endl <<
|
||||
"Any non-option parameter is stuffed into the keyboard buffer." << endl;
|
||||
"-S<sortspec> Sorts all mail areas according to the sort specs." << std::endl <<
|
||||
"-T<seconds> Set a timeout value. GoldED+ will auto-exit after timeout." << std::endl <<
|
||||
"-V or -VV Verbose or Very verbose (-VV) config compile. Use -VV to debug." << std::endl <<
|
||||
"-W Write a GOLDAREA.INC file with AREADEF's of all mail areas." << std::endl <<
|
||||
"-X, -Y, -Z Reserved for debugging purposes." << std::endl <<
|
||||
std::endl <<
|
||||
"Any non-option parameter is stuffed into the keyboard buffer." << std::endl;
|
||||
|
||||
exit(0);
|
||||
}
|
||||
@@ -642,7 +642,7 @@ void Initialize(int argc, char* argv[]) {
|
||||
InstallDetect(cmdlineinstpath);
|
||||
|
||||
if(not fexist(CFG->goldcfg)) {
|
||||
cout << "*** Cannot start: " << CFG->goldcfg << " not found! ***" << endl;
|
||||
std::cout << "*** Cannot start: " << CFG->goldcfg << " not found! ***" << std::endl;
|
||||
errorlevel = EXIT_NONAME;
|
||||
exit(0);
|
||||
}
|
||||
@@ -653,7 +653,7 @@ void Initialize(int argc, char* argv[]) {
|
||||
// Call install finish procedure
|
||||
if(cmdlineinstall) {
|
||||
if(InstallFinish()) {
|
||||
cout << "*** INSTALL NOT COMPLETED ***" << endl;
|
||||
std::cout << "*** INSTALL NOT COMPLETED ***" << std::endl;
|
||||
remove(CFG->goldcfg);
|
||||
errorlevel = EXIT_NONAME;
|
||||
exit(0);
|
||||
@@ -704,12 +704,12 @@ void Initialize(int argc, char* argv[]) {
|
||||
// Report detected multitasker
|
||||
if(not quiet) {
|
||||
if(gmtsk.detected)
|
||||
cout << "* Running under " << gmtsk.name << "." << endl;
|
||||
std::cout << "* Running under " << gmtsk.name << "." << std::endl;
|
||||
}
|
||||
|
||||
if(cfgerrors) {
|
||||
cout << "* Total CFG errors found: " << cfgerrors
|
||||
<< ". Press almost any key to continue." << endl;
|
||||
std::cout << "* Total CFG errors found: " << cfgerrors
|
||||
<< ". Press almost any key to continue." << std::endl;
|
||||
kbclear();
|
||||
waitkey();
|
||||
}
|
||||
@@ -998,7 +998,7 @@ void Initialize(int argc, char* argv[]) {
|
||||
WideSharemode = CFG->sharemode;
|
||||
WideUsernames = CFG->username.size();
|
||||
WideUsername = new const char*[WideUsernames];
|
||||
vector<Node>::iterator i;
|
||||
std::vector<Node>::iterator i;
|
||||
int w;
|
||||
for(w = 0, i = CFG->username.begin(); w < WideUsernames; w++, i++)
|
||||
WideUsername[w] = i->name;
|
||||
|
@@ -2743,7 +2743,7 @@ int LoadCharset(const char* imp, const char* exp, int query) {
|
||||
}
|
||||
|
||||
// Find and load charset table
|
||||
vector<Map>::iterator xlt;
|
||||
std::vector<Map>::iterator xlt;
|
||||
for(n = 0, xlt = CFG->xlatcharset.begin(); xlt != CFG->xlatcharset.end(); xlt++, n++) {
|
||||
if(striinc(xlt->imp, imp) and striinc(xlt->exp, exp)) {
|
||||
// Already loaded?
|
||||
|
@@ -772,7 +772,7 @@ int ChangeUsername() {
|
||||
|
||||
if(not CFG->username.empty()) {
|
||||
Listi = (char**)throw_calloc(CFG->username.size()+1, sizeof(char*));
|
||||
vector<Node>::iterator i;
|
||||
std::vector<Node>::iterator i;
|
||||
for(n = 0, i = CFG->username.begin(); i != CFG->username.end(); n++, i++) {
|
||||
i->addr.make_string(adrs);
|
||||
sprintf(buf, " %-35s %s ", i->name, adrs);
|
||||
@@ -786,7 +786,7 @@ int ChangeUsername() {
|
||||
if(n != -1) {
|
||||
CFG->usernameno = n;
|
||||
AA->SetUsername(CFG->username[n]);
|
||||
for(vector<gaka>::iterator a = CFG->aka.begin(); a != CFG->aka.end(); a++) {
|
||||
for(std::vector<gaka>::iterator a = CFG->aka.begin(); a != CFG->aka.end(); a++) {
|
||||
if(AA->Username().addr.match(a->addr)) {
|
||||
AA->SetAka(a->addr);
|
||||
break;
|
||||
@@ -818,7 +818,7 @@ int ChangeTemplate() {
|
||||
|
||||
if(not CFG->tpl.empty()) {
|
||||
Listi = (char**)throw_calloc(CFG->tpl.size()+1, sizeof(char*));
|
||||
vector<Tpl>::iterator t;
|
||||
std::vector<Tpl>::iterator t;
|
||||
for(n = 0, t = CFG->tpl.begin(); t != CFG->tpl.end(); n++, t++) {
|
||||
t->match.make_string(adrs);
|
||||
sprintf(buf, " %-45s %s ", t->name, adrs);
|
||||
@@ -852,7 +852,7 @@ int ChangeTemplate() {
|
||||
|
||||
int ChangeAka() {
|
||||
int n;
|
||||
vector<gaka>::iterator i;
|
||||
std::vector<gaka>::iterator i;
|
||||
int startat = 0;
|
||||
char** Listi;
|
||||
char addr[100], buf[100];
|
||||
@@ -900,7 +900,7 @@ int ChangeXlatImport() {
|
||||
|
||||
if(not CFG->xlatcharset.empty()) {
|
||||
Listi = (char**)throw_calloc(CFG->xlatcharset.size()+2, sizeof(char*));
|
||||
vector<Map>::iterator xlt;
|
||||
std::vector<Map>::iterator xlt;
|
||||
for(xlt = CFG->xlatcharset.begin(); xlt != CFG->xlatcharset.end(); xlt++) {
|
||||
if(strieql(xlt->exp, CFG->xlatlocalset)) {
|
||||
maximport = MaxV(maximport, (int)strlen(xlt->imp));
|
||||
|
@@ -168,7 +168,7 @@ void GMsgList::ReadMlst(int n) {
|
||||
}
|
||||
ml->goldmark = goldmark;
|
||||
|
||||
for(vector<Node>::iterator x = CFG->username.begin(); x != CFG->username.end(); x++) {
|
||||
for(std::vector<Node>::iterator x = CFG->username.begin(); x != CFG->username.end(); x++) {
|
||||
if(strieql(msg.By(), x->name)) {
|
||||
ml->high |= MLST_HIGH_FROM;
|
||||
msg.attr.fmu1();
|
||||
@@ -625,7 +625,7 @@ private:
|
||||
|
||||
gwindow window;
|
||||
GMsg msg;
|
||||
vector<ThreadEntry> list;
|
||||
std::vector<ThreadEntry> list;
|
||||
ThreadEntry t;
|
||||
uint h_offset;
|
||||
|
||||
@@ -856,7 +856,7 @@ void GThreadlist::print_line(uint idx, uint pos, bool isbar) {
|
||||
|
||||
int attr = attrw;
|
||||
|
||||
for(vector<Node>::iterator x = CFG->username.begin(); x != CFG->username.end(); x++)
|
||||
for(std::vector<Node>::iterator x = CFG->username.begin(); x != CFG->username.end(); x++)
|
||||
if(strieql(msg.By(), x->name)) {
|
||||
attr = attrh;
|
||||
break;
|
||||
|
@@ -853,7 +853,7 @@ void Lookup(GMsg* msg, Addr* addr, char* name, int topline, char* status) {
|
||||
strcpy(tmpname, name);
|
||||
|
||||
if(not CFG->addressmacro.empty()) {
|
||||
vector<AddrMacro>::iterator n;
|
||||
std::vector<AddrMacro>::iterator n;
|
||||
ptr = name;
|
||||
strcpy(buf, ptr);
|
||||
for(n=CFG->addressmacro.begin(); n != CFG->addressmacro.end(); n++) {
|
||||
|
@@ -87,18 +87,18 @@ void InitSound() {
|
||||
|
||||
// Find out if there are any sound files to be played
|
||||
#ifdef GOLD_SOUNDSUPPORT
|
||||
vector<GEvent>::iterator n;
|
||||
std::vector<GEvent>::iterator n;
|
||||
for(n = CFG->event.begin(); n != CFG->event.end(); n++) {
|
||||
if(n->play.type == PLAY_VOC) {
|
||||
snd = new gsound;
|
||||
if(snd->is_installed()) {
|
||||
if(not quiet)
|
||||
cout << "* Soundcard support was successfully initialized." << endl;
|
||||
std::cout << "* Soundcard support was successfully initialized." << std::endl;
|
||||
atexit(ResetSound);
|
||||
}
|
||||
else {
|
||||
if(not quiet)
|
||||
cout << "* Soundcard support could NOT be initialized!" << endl;
|
||||
std::cout << "* Soundcard support could NOT be initialized!" << std::endl;
|
||||
ResetSound();
|
||||
}
|
||||
break;
|
||||
@@ -179,7 +179,7 @@ int HandleGEvent(uint event) {
|
||||
}
|
||||
|
||||
if(CFG) {
|
||||
vector<GEvent>::iterator n;
|
||||
std::vector<GEvent>::iterator n;
|
||||
for(n = CFG->event.begin(); n != CFG->event.end(); n++) {
|
||||
if(event == n->type) {
|
||||
switch(n->command) {
|
||||
|
@@ -29,17 +29,17 @@
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
vector<int> post_xparea;
|
||||
std::vector<int> post_xparea;
|
||||
uint position;
|
||||
ulong msgcount = 0;
|
||||
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
string &strtrimline(string &p) {
|
||||
std::string &strtrimline(std::string &p) {
|
||||
|
||||
if(not p.empty()) {
|
||||
string::iterator trail = p.end();
|
||||
std::string::iterator trail = p.end();
|
||||
while(trail != p.begin()) {
|
||||
--trail;
|
||||
if(not strchr(" \t\r\n", *trail) and not issoftcr(*trail)) {
|
||||
@@ -231,7 +231,7 @@ static bool have_origin(GMsg *msg) {
|
||||
static void MakeMsg3(int& mode, GMsg* msg) {
|
||||
|
||||
int n;
|
||||
vector<gaka>::iterator u;
|
||||
std::vector<gaka>::iterator u;
|
||||
|
||||
msg->charsetlevel = 0;
|
||||
if(*AA->Xlatexport()) {
|
||||
@@ -265,7 +265,7 @@ static void MakeMsg3(int& mode, GMsg* msg) {
|
||||
msg->oorig = msg->orig;
|
||||
if(AA->isnet() and msg->orig.point) {
|
||||
for(u = CFG->aka.begin(); u != CFG->aka.end(); u++) {
|
||||
if(not memcmp(u, &msg->orig, sizeof(Addr))) {
|
||||
if(not memcmp(&(*u), &msg->orig, sizeof(Addr))) {
|
||||
// Use fakenet to everybody
|
||||
if(u->pointnet) {
|
||||
msg->oorig.net = u->pointnet; // Create fake address
|
||||
@@ -280,7 +280,7 @@ static void MakeMsg3(int& mode, GMsg* msg) {
|
||||
DoKludges(mode, msg);
|
||||
|
||||
if(cc) {
|
||||
string temp;
|
||||
std::string temp;
|
||||
update_statuslinef(LNG->StatusCC, msg->to, msg->dest.make_string(temp).c_str());
|
||||
}
|
||||
|
||||
@@ -369,7 +369,7 @@ static void MakeMsg3(int& mode, GMsg* msg) {
|
||||
cmsg->references = msg->references;
|
||||
AA->NewMsgno(cmsg);
|
||||
{
|
||||
string temp;
|
||||
std::string temp;
|
||||
update_statuslinef(LNG->StatusCC, cmsg->to, cmsg->dest.make_string(temp).c_str());
|
||||
}
|
||||
|
||||
@@ -383,7 +383,7 @@ static void MakeMsg3(int& mode, GMsg* msg) {
|
||||
cmsg->oorig = cmsg->orig;
|
||||
if(AA->isnet() and cmsg->orig.point) {
|
||||
for(u = CFG->aka.begin(); u != CFG->aka.end(); u++) {
|
||||
if(not memcmp(u, &cmsg->orig, sizeof(Addr))) {
|
||||
if(not memcmp(&(*u), &cmsg->orig, sizeof(Addr))) {
|
||||
// Use fakenet to everybody
|
||||
if(u->pointnet) {
|
||||
cmsg->oorig.net = u->pointnet; // Create fake address
|
||||
@@ -482,7 +482,7 @@ static void MakeMsg2(int& mode, int& status, int& forwstat, int& topline, GMsg*
|
||||
if(status == MODE_CHANGE or (mode == MODE_FORWARD and status == MODE_SAVE)) {
|
||||
if(mode == MODE_CHANGE) {
|
||||
if(stricmp(msg->By(), AA->Username().name)) {
|
||||
vector<Node>::iterator x;
|
||||
std::vector<Node>::iterator x;
|
||||
for(n = 0, x = CFG->username.begin(); x != CFG->username.end(); n++, x++) {
|
||||
if(strieql(x->name, msg->By())) {
|
||||
n = 0;
|
||||
|
@@ -220,7 +220,7 @@ char* TokenXlat(int mode, char* input, GMsg* msg, GMsg* oldmsg, int origarea);
|
||||
void Rot13(GMsg* msg);
|
||||
void ResetMsg(GMsg* msg);
|
||||
int DoCarboncopy(GMsg* msg, GMsg** carbon);
|
||||
void DoCrosspost(GMsg* msg, vector<int> &postareas);
|
||||
void DoCrosspost(GMsg* msg, std::vector<int> &postareas);
|
||||
char* ParseInternetAddr(char* __string, char* __name, char* __addr);
|
||||
|
||||
|
||||
@@ -392,7 +392,7 @@ void maketitle();
|
||||
void ProgMeter(int mode, int xx, int yy, long len, long barlen, int attr, long pos, long size);
|
||||
int ReadCfg(const char* cfg, int ignoreunknown=false);
|
||||
void ScanMsgTxtForAddr(GMsg* msg);
|
||||
gkey SearchKey(gkey key, list<CmdKey>::iterator keys, int totkeys);
|
||||
gkey SearchKey(gkey key, std::list<CmdKey>::iterator keys, int totkeys);
|
||||
int SearchTaglist(Echo* taglist, char* tag);
|
||||
void set_title(const char* t, int p, int a);
|
||||
void title_shadow();
|
||||
|
@@ -388,7 +388,7 @@ void Area::RandomizeData(int mode) {
|
||||
CFG->grp.GetItm(GRP_XLATIMPORT, adat->xlatimport, sizeof(adat->xlatimport));
|
||||
}
|
||||
|
||||
vector<MailList>::iterator z;
|
||||
std::vector<MailList>::iterator z;
|
||||
for(z = CFG->mailinglist.begin(); z != CFG->mailinglist.end(); z++)
|
||||
if(strieql(echoid(), z->echoid)) {
|
||||
strcpy(adat->whoto, *z->contribution ? z->contribution : z->sender);
|
||||
|
@@ -815,7 +815,7 @@ int MsgIsTwit(GMsg* msg, bool& istwitto, bool& istwitsubj) {
|
||||
istwitto = istwitsubj = false;
|
||||
|
||||
// Check for twit names
|
||||
vector<Node>::iterator tn;
|
||||
std::vector<Node>::iterator tn;
|
||||
for(tn = CFG->twitname.begin(); tn != CFG->twitname.end(); tn++) {
|
||||
if(msg->orig.match(tn->addr)) {
|
||||
if(*tn->name == NUL or strwild(msg->By(), tn->name)) {
|
||||
@@ -875,14 +875,14 @@ int LoadMessage(GMsg* msg, int margin) {
|
||||
|
||||
// Mark message as received, if it is for us
|
||||
if(msg->msgno and not AA->attr().hex()) {
|
||||
for(vector<Node>::iterator n = CFG->username.begin(); n != CFG->username.end(); n++) {
|
||||
for(std::vector<Node>::iterator n = CFG->username.begin(); n != CFG->username.end(); n++) {
|
||||
// Check TO:
|
||||
if(msg->dest.match(n->addr)) {
|
||||
if(strieql(n->name, msg->To())) {
|
||||
if(n->addr.net != GFTN_ALL or msg->dest.net == 0 or not AA->isnet())
|
||||
msg->attr.tou1(); // Set highlight mark
|
||||
else {
|
||||
for(vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
for(std::vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
if(msg->dest.match(x->addr)) {
|
||||
msg->attr.tou1(); // Set highlight mark
|
||||
break;
|
||||
@@ -898,7 +898,7 @@ int LoadMessage(GMsg* msg, int margin) {
|
||||
if(n->addr.net != GFTN_ALL or msg->orig.net == 0 or not AA->isnet())
|
||||
msg->attr.fmu1(); // Set highlight mark
|
||||
else {
|
||||
for(vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
for(std::vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
if(msg->orig.match(x->addr)) {
|
||||
msg->attr.fmu1(); // Set highlight mark
|
||||
break;
|
||||
|
@@ -320,7 +320,7 @@ void GotoMsgno() {
|
||||
|
||||
gwindow iwindow(whandle());
|
||||
|
||||
string fbuf = buf;
|
||||
std::string fbuf = buf;
|
||||
gwinput2 iform(iwindow);
|
||||
iform.setup(C_HEADW, C_HEADW, C_HEADI, _box_table(W_BHEAD, 13), true);
|
||||
iform.add_field(0, wrow, 8, 5, fbuf, 20, gwinput::cvt_none, gwinput::entry_new);
|
||||
@@ -524,7 +524,7 @@ int ExternUtil(GMsg* msg, int utilno) {
|
||||
strcpy(editorfile, AddPath(CFG->goldpath, EDIT->File()));
|
||||
mktemp(strcpy(tmpfile, AddPath(CFG->goldpath, "GDXXXXXX")));
|
||||
|
||||
vector<ExtUtil>::iterator extutil = CFG->externutil.begin();
|
||||
std::vector<ExtUtil>::iterator extutil = CFG->externutil.begin();
|
||||
|
||||
for(int utlno=0; extutil != CFG->externutil.end(); utlno++, extutil++) {
|
||||
|
||||
@@ -749,9 +749,9 @@ void make_pathreport(const char* reportfile) {
|
||||
gfile fp;
|
||||
fp.fopen(reportfile, "wt");
|
||||
if(fp) {
|
||||
string path;
|
||||
std::string path;
|
||||
ftn_addr address;
|
||||
vector<ftn_addr> alist;
|
||||
std::vector<ftn_addr> alist;
|
||||
GMsg* msg = (GMsg*)throw_calloc(1, sizeof(GMsg));
|
||||
w_progress(MODE_NEW, C_INFOW, 0, AA->Msgn.Count(), "Generating PATH report");
|
||||
for(int n=AA->Msgn.Count(); n>=AA->lastread(); n--) {
|
||||
@@ -769,7 +769,7 @@ void make_pathreport(const char* reportfile) {
|
||||
INam buf;
|
||||
strcpy(buf, msg->By());
|
||||
strchg(buf, ' ', '_');
|
||||
string temp;
|
||||
std::string temp;
|
||||
fp.printf("%s %s ", buf, address.make_string(temp).c_str());
|
||||
path = "";
|
||||
Line* line = msg->lin;
|
||||
|
@@ -112,7 +112,7 @@ char* UnfoldLine(char* mptr) {
|
||||
int CheckMailinglists(GMsg* msg, int current) {
|
||||
|
||||
if(AA->isemail()) {
|
||||
vector<MailList>::iterator z;
|
||||
std::vector<MailList>::iterator z;
|
||||
for(z = CFG->mailinglist.begin(); z != CFG->mailinglist.end(); z++)
|
||||
if(z->sender_is_pattern) {
|
||||
golded_search_manager srchmgr;
|
||||
@@ -134,7 +134,7 @@ int CheckMailinglists(GMsg* msg, int current) {
|
||||
int CheckMailinglists(const char* what, int current) {
|
||||
|
||||
if(AA->isemail()) {
|
||||
vector<MailList>::iterator z;
|
||||
std::vector<MailList>::iterator z;
|
||||
for(z = CFG->mailinglist.begin(); z != CFG->mailinglist.end(); z++)
|
||||
if(not z->sender_is_pattern and strieql(what, z->sender)) {
|
||||
int areano = AL.AreaEchoToNo(z->echoid);
|
||||
|
@@ -217,7 +217,7 @@ void golded_search_manager::prepare_from_string(const char* prompt, int what) {
|
||||
|
||||
bool golded_search_manager::search(GMsg* msg, bool quick, bool shortcircuit) {
|
||||
|
||||
search_item* item = items.begin();
|
||||
std::vector<search_item>::iterator item = items.begin();
|
||||
bool exit = false;
|
||||
bool and_cycle = false;
|
||||
bool or_cycle = false;
|
||||
@@ -533,7 +533,7 @@ void AdvancedSearch(GMsg*, int&, int&) {
|
||||
|
||||
iform.setup(idle_color, active_color, edit_color, _box_table(border_type, 13), true);
|
||||
|
||||
string buffers[9*3 + 6];
|
||||
std::string buffers[9*3 + 6];
|
||||
|
||||
int i = 0;
|
||||
for(int r=0; r<9; r++) {
|
||||
|
@@ -41,7 +41,7 @@ bool is_user(const char* name) {
|
||||
if(strieql(name, AA->Username().name))
|
||||
return true;
|
||||
// We should check all misspells too
|
||||
for(vector<Node>:: iterator u = CFG->username.begin(); u != CFG->username.end(); u++)
|
||||
for(std::vector<Node>:: iterator u = CFG->username.begin(); u != CFG->username.end(); u++)
|
||||
if(strieql(name, u->name))
|
||||
return true;
|
||||
return false;
|
||||
@@ -183,7 +183,7 @@ int TemplateToText(int mode, GMsg* msg, GMsg* oldmsg, const char* tpl, int origa
|
||||
if(AA->Templatematch() and not (CFG->tplno or AA->isnewsgroup() or AA->isemail())) {
|
||||
if(not ((mode == MODE_NEW or mode == MODE_REPLYCOMMENT or mode == MODE_FORWARD)
|
||||
and (AA->isecho() or AA->islocal()))) {
|
||||
vector<Tpl>::iterator tp;
|
||||
std::vector<Tpl>::iterator tp;
|
||||
for(tp = CFG->tpl.begin(); tp != CFG->tpl.end(); tp++)
|
||||
if(tp->match.net and msg->dest.match(tp->match)) {
|
||||
strcpy(tplfile, tp->file);
|
||||
@@ -680,7 +680,7 @@ int TemplateToText(int mode, GMsg* msg, GMsg* oldmsg, const char* tpl, int origa
|
||||
}
|
||||
|
||||
// Invalidate kludge chars
|
||||
string& tempref = strtrim(oldmsg->line[n]->txt);
|
||||
std::string& tempref = strtrim(oldmsg->line[n]->txt);
|
||||
replace(tempref.begin(), tempref.end(), CTRL_A, '@');
|
||||
quote = tempref.c_str();
|
||||
|
||||
@@ -848,14 +848,14 @@ void ChangeMsg() {
|
||||
AA->LoadMsg(reader_msg, reader_msg->msgno, CFG->dispmargin-(int)CFG->switches.get(disppagebar));
|
||||
}
|
||||
|
||||
for(vector<Node>:: iterator u = CFG->username.begin(); u != CFG->username.end(); u++)
|
||||
for(std::vector<Node>:: iterator u = CFG->username.begin(); u != CFG->username.end(); u++)
|
||||
// Check FROM:
|
||||
if(reader_msg->orig.match(u->addr)) {
|
||||
if(strieql(u->name, reader_msg->By())) {
|
||||
if(u->addr.net != GFTN_ALL or reader_msg->orig.net == 0 or not AA->isnet())
|
||||
reader_keyok = NO;
|
||||
else {
|
||||
for(vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
for(std::vector<gaka>::iterator x = CFG->aka.begin(); x != CFG->aka.end(); x++) {
|
||||
if(reader_msg->orig.match(x->addr)) {
|
||||
reader_keyok = NO;
|
||||
break;
|
||||
|
@@ -392,7 +392,7 @@ bool guserbase::edit_entry(uint idx) {
|
||||
bool guserbase::find_entry(char* name, bool lookup) {
|
||||
|
||||
if(not strblank(name)) {
|
||||
string tmpaddr;
|
||||
std::string tmpaddr;
|
||||
gusrbaseentry old_entry = entry;
|
||||
uint old_index = index;
|
||||
|
||||
@@ -757,7 +757,7 @@ void guserbase::update_addressbook(GMsg* msg, bool reverse, bool force) {
|
||||
|
||||
// 5. It's the mailinglist's sender address
|
||||
if(AA->isemail()) {
|
||||
vector<MailList>::iterator z;
|
||||
std::vector<MailList>::iterator z;
|
||||
for(z = CFG->mailinglist.begin(); z != CFG->mailinglist.end(); z++)
|
||||
if(strieql(z->sender, name) or strieql(z->sender, iaddr))
|
||||
return;
|
||||
|
@@ -85,23 +85,23 @@ class guserbase;
|
||||
|
||||
class addressbook_form : public gwinput2 {
|
||||
|
||||
string macro;
|
||||
string name;
|
||||
string fidoaddr;
|
||||
string iaddr;
|
||||
string pseudo;
|
||||
string organisation;
|
||||
string snail1;
|
||||
string snail2;
|
||||
string snail3;
|
||||
string dataphone;
|
||||
string voicephone;
|
||||
string faxphone;
|
||||
string homepage;
|
||||
string group;
|
||||
string comment1;
|
||||
string comment2;
|
||||
string comment3;
|
||||
std::string macro;
|
||||
std::string name;
|
||||
std::string fidoaddr;
|
||||
std::string iaddr;
|
||||
std::string pseudo;
|
||||
std::string organisation;
|
||||
std::string snail1;
|
||||
std::string snail2;
|
||||
std::string snail3;
|
||||
std::string dataphone;
|
||||
std::string voicephone;
|
||||
std::string faxphone;
|
||||
std::string homepage;
|
||||
std::string group;
|
||||
std::string comment1;
|
||||
std::string comment2;
|
||||
std::string comment3;
|
||||
|
||||
bool validate();
|
||||
void before();
|
||||
|
@@ -452,9 +452,9 @@ static int KeyCmp(const gkey* a, const gkey* b) {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
gkey SearchKey(gkey key, list<CmdKey>::iterator keys, int totkeys) {
|
||||
gkey SearchKey(gkey key, std::list<CmdKey>::iterator keys, int totkeys) {
|
||||
|
||||
list<CmdKey>::iterator kmin;
|
||||
std::list<CmdKey>::iterator kmin;
|
||||
int again = 0;
|
||||
|
||||
do {
|
||||
|
@@ -41,7 +41,7 @@ int edit_string(char* buf, int buf_size, char* title, int helpcat) {
|
||||
|
||||
gwinput2 iform(window);
|
||||
|
||||
string buf2 = buf;
|
||||
std::string buf2 = buf;
|
||||
iform.setup(C_ASKW, C_ASKW, C_ASKQ, _box_table(W_BASK, 13), true);
|
||||
iform.add_field(0, 0, 1, 59, buf2, buf_size, gwinput::cvt_none, fieldupd);
|
||||
vcurshow();
|
||||
@@ -68,7 +68,7 @@ bool edit_pathname(char* buf, int buf_size, char* title, int helpcat) {
|
||||
if(not edit_string(buf, buf_size, title, helpcat))
|
||||
return false;
|
||||
|
||||
vector<FileAlias>::iterator z;
|
||||
std::vector<FileAlias>::iterator z;
|
||||
for(z = CFG->filealias.begin(); z != CFG->filealias.end(); z++) {
|
||||
if(strieql(buf, z->alias)) {
|
||||
strcpy(buf, z->file);
|
||||
@@ -191,8 +191,9 @@ int AkaMatchOne(const ftn_addr* mask, const ftn_addr* addr) {
|
||||
int AkaMatch(ftn_addr* match, const ftn_addr* addr) {
|
||||
|
||||
int aka;
|
||||
std::vector<AkaMatchG>::iterator am;
|
||||
|
||||
for(vector<AkaMatchG>::iterator am = CFG->akamatch.begin(), aka=0; am != CFG->akamatch.end(); am++, aka++) {
|
||||
for(am = CFG->akamatch.begin(), aka=0; am != CFG->akamatch.end(); am++, aka++) {
|
||||
if(addr->match(am->mask)) {
|
||||
int akano = GetAkaNo(am->aka);
|
||||
if(akano != -1) {
|
||||
@@ -205,7 +206,7 @@ int AkaMatch(ftn_addr* match, const ftn_addr* addr) {
|
||||
int bestaka = -1;
|
||||
int bestmatch = 0;
|
||||
int matchaka = 0;
|
||||
vector<gaka>::iterator a;
|
||||
std::vector<gaka>::iterator a;
|
||||
|
||||
for(a = CFG->aka.begin(), aka = 0; a != CFG->aka.end(); aka++, a++) {
|
||||
|
||||
|
@@ -114,15 +114,15 @@ class GAreaListScan {
|
||||
|
||||
private:
|
||||
|
||||
vector< pair<string, string> > container;
|
||||
vector< pair<string, string> >::iterator currposn;
|
||||
std::vector< std::pair<std::string, std::string> > container;
|
||||
std::vector< std::pair<std::string, std::string> >::iterator currposn;
|
||||
|
||||
public:
|
||||
|
||||
inline GAreaListScan() { currposn = container.end(); }
|
||||
inline ~GAreaListScan() {}
|
||||
|
||||
inline void Add(pair<string, string> p) { container.push_back(p); currposn = container.end(); }
|
||||
inline void Add(std::pair<std::string, std::string> p) { container.push_back(p); currposn = container.end(); }
|
||||
|
||||
inline void Reset() { container.clear(); currposn = container.end(); }
|
||||
|
||||
@@ -167,7 +167,7 @@ struct ggoldlast {
|
||||
|
||||
class Area;
|
||||
|
||||
typedef vector<Area *>::iterator area_iterator;
|
||||
typedef std::vector<Area *>::iterator area_iterator;
|
||||
|
||||
class AreaList {
|
||||
|
||||
@@ -182,7 +182,7 @@ private:
|
||||
public:
|
||||
|
||||
// Index of areas in the list
|
||||
vector<Area *> idx;
|
||||
std::vector<Area *> idx;
|
||||
|
||||
// Area pointer
|
||||
area_iterator item;
|
||||
|
Reference in New Issue
Block a user