Random fixes
This commit is contained in:
parent
2b647df906
commit
293685cd8e
@ -12,6 +12,10 @@ ______________________________________________________________________
|
||||
Notes for GoldED+ 1.1.5, /snapshot/
|
||||
______________________________________________________________________
|
||||
|
||||
- Fixed lastread problem after edit externutils (PGP, etc.).
|
||||
|
||||
- Oops, EchoAreaDefaults was not applied to the includes. Fixed.
|
||||
|
||||
+ Added EchoAreaDefaults support to Fidoconfig parser.
|
||||
|
||||
+ Synchronet configuration parser now will use short description
|
||||
|
@ -585,7 +585,12 @@ int GMenuEditfile::Run(GMsg* __msg) {
|
||||
|
||||
default:
|
||||
if(finaltag >= TAG_UTILS) {
|
||||
XlatName __oldxlatimport;
|
||||
// Save current charset
|
||||
strcpy(__oldxlatimport, AA->Xlatimport());
|
||||
AA->SetXlatimport(CFG->xlatlocalset);
|
||||
ExternUtil(__msg, EDIT->SaveUtil.Number(finaltag-TAG_UTILS));
|
||||
AA->SetXlatimport(__oldxlatimport);
|
||||
BodyView->Use(AA, __msg, _topline);
|
||||
BodyView->Paint();
|
||||
}
|
||||
|
@ -613,7 +613,6 @@ int ExternUtil(GMsg *msg, ExtUtil *extutil) {
|
||||
if(tmpfile[0] != NUL)
|
||||
WipeFile(tmpfile, 0);
|
||||
|
||||
reader_keyok = true;
|
||||
return YES;
|
||||
}
|
||||
|
||||
@ -665,11 +664,11 @@ void ExternUtilMenu(GMsg* msg) {
|
||||
extutil.utilno = 0;
|
||||
strxcpy(extutil.cmdline, cmdline, sizeof(extutil.cmdline));
|
||||
extutil.options = CFG->externoptions;
|
||||
ExternUtil(msg, &extutil);
|
||||
reader_keyok = ExternUtil(msg, &extutil);
|
||||
}
|
||||
}
|
||||
else {
|
||||
ExternUtil(msg, &CFG->externutil[n-1]);
|
||||
reader_keyok = ExternUtil(msg, &CFG->externutil[n-1]);
|
||||
}
|
||||
}
|
||||
for(n=CFG->externutil.size()+1; n; n--)
|
||||
|
@ -45,7 +45,6 @@
|
||||
#include <sys/nls.h>
|
||||
#define tolower(c) _nls_tolower((unsigned char)(c))
|
||||
#define toupper(c) _nls_toupper((unsigned char)(c))
|
||||
#endif
|
||||
#elif defined(__WIN32__)
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@ -55,19 +54,20 @@ __inline__ int toupper(int c) { return tu[c]; }
|
||||
}
|
||||
#else
|
||||
extern char tl[256], tu[256];
|
||||
#define tolower(c) tl[(int)(unsigned char)c]
|
||||
#define toupper(c) tu[(int)(unsigned char)c]
|
||||
#define tolower(c) tl[(int)(unsigned char)(c)]
|
||||
#define toupper(c) tu[(int)(unsigned char)(c)]
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
// NLS chars detected by converting to lower or upper case and in case they don't match they treated as characters
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
// NLS chars detected by converting to lower or upper case and in case they don't match they treated as characters
|
||||
__inline__ int isxalnum(char c) { return isascii(c) ? isalnum(c) : (c != tolower(c)) || (c != toupper(c)); }
|
||||
extern __inline__ int isxalnum(char c) { return isascii(c) ? isalnum(c) : (c != tolower(c)) || (c != toupper(c)); }
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -267,8 +267,9 @@ protected:
|
||||
void ReadFMail116(FILE* fp, char* path, char* file, char* options);
|
||||
#endif
|
||||
#ifndef GCFG_NOFIDOCONF
|
||||
AreaCfg echoareadefaults;
|
||||
bool ReadHPTLine(FILE* f, std::string* s, bool add=false, int state=0);
|
||||
void ReadHPTFile(char* path, char* file, char* options, char* origin, int group);
|
||||
void ReadHPTFile(char* path, char* file, char* origin, int group);
|
||||
#endif
|
||||
#ifndef GCFG_NOIMAIL
|
||||
void ReadIMail160(char* options, char* file, char* impath);
|
||||
|
@ -155,7 +155,7 @@ void gareafile::gettok(char** key, char** val) {
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
|
||||
void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin, int group) {
|
||||
void gareafile::ReadHPTFile(char* path, char* file, char* origin, int group) {
|
||||
|
||||
const word CRC_ADDRESS = 0xFDD6;
|
||||
const word CRC_INCLUDE = 0x379B;
|
||||
@ -170,7 +170,7 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
const word CRC_COMMENTCHAR = 0xE2CC;
|
||||
const word CRC_ECHOAREADEFAULTS = 0x2CBB;
|
||||
|
||||
AreaCfg aa, ad;
|
||||
AreaCfg aa;
|
||||
Path buf2;
|
||||
|
||||
FILE* fp = fsopen(file, "rb", sharemode);
|
||||
@ -181,7 +181,6 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
std::cout << "* Reading " << file << std::endl;
|
||||
|
||||
aa.reset();
|
||||
ad.reset();
|
||||
|
||||
std::string s;
|
||||
while(ReadHPTLine(fp, &s)) {
|
||||
@ -191,10 +190,6 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
char *alptr = throw_xstrdup(s.c_str());
|
||||
char *ptr = alptr;
|
||||
|
||||
aa.type = GMB_NONE;
|
||||
aa.msgbase = fidomsgtype;
|
||||
aa.groupid = group;
|
||||
|
||||
char* key;
|
||||
char* val = ptr;
|
||||
gettok(&key, &val);
|
||||
@ -221,7 +216,7 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
if(strchg(buf2, '[', '%') != 0)
|
||||
strchg(buf2, ']', '%');
|
||||
MakePathname(buf2, path, buf2);
|
||||
ReadHPTFile(path, buf2, options, origin, group);
|
||||
ReadHPTFile(path, buf2, origin, group);
|
||||
break;
|
||||
case CRC_COMMENTCHAR:
|
||||
if((strlen(val) == 3) and (val[0] == val[2]) and strpbrk(val, "\'\""))
|
||||
@ -239,11 +234,11 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
aa.type = GMB_LOCAL;
|
||||
break;
|
||||
case CRC_ECHOAREA:
|
||||
aa = ad;
|
||||
aa = echoareadefaults;
|
||||
aa.type = GMB_ECHO;
|
||||
break;
|
||||
case CRC_ECHOAREADEFAULTS:
|
||||
ad.reset();
|
||||
echoareadefaults.reset();
|
||||
aa.type = GMB_DEFAULT;
|
||||
break;
|
||||
}
|
||||
@ -346,7 +341,7 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
AddNewArea(aa);
|
||||
break;
|
||||
case GMB_DEFAULT:
|
||||
ad = aa;
|
||||
echoareadefaults = aa;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
@ -404,7 +399,11 @@ void gareafile::ReadHPT(char* tag) {
|
||||
|
||||
CfgJAMSMAPIHighwater(true);
|
||||
|
||||
ReadHPTFile(path, file, options, origin, defaultgroup);
|
||||
echoareadefaults.type = GMB_NONE;
|
||||
echoareadefaults.msgbase = fidomsgtype;
|
||||
echoareadefaults.groupid = defaultgroup;
|
||||
|
||||
ReadHPTFile(path, file, origin, defaultgroup);
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user