Fix configuration parser problems
This commit is contained in:
parent
5d49473f91
commit
d0fc0d7104
@ -12,6 +12,12 @@ ______________________________________________________________________
|
|||||||
Notes for GoldED+ 1.1.5, /snapshot/
|
Notes for GoldED+ 1.1.5, /snapshot/
|
||||||
______________________________________________________________________
|
______________________________________________________________________
|
||||||
|
|
||||||
|
- GoldED+ should now properly prepend data/subs path to the Synchronet
|
||||||
|
bases, so copying of msgs.cnf to that directory should not be done
|
||||||
|
anymore in order to make Synchronet areafile reader working.
|
||||||
|
|
||||||
|
- Fixed the warning line if SeqMsgId set to MAYBE.
|
||||||
|
|
||||||
- GoldED+/W32 will not issue warning about too long commandline under
|
- GoldED+/W32 will not issue warning about too long commandline under
|
||||||
NT.
|
NT.
|
||||||
|
|
||||||
|
@ -55,10 +55,32 @@ void gareafile::ReadSynchronet(char* tag) {
|
|||||||
|
|
||||||
if(not fexist(file)) {
|
if(not fexist(file)) {
|
||||||
AddBackslash(file);
|
AddBackslash(file);
|
||||||
strcat(file, "msgs.cnf");
|
strxcat(file, "msgs.cnf", sizeof(Path));
|
||||||
}
|
}
|
||||||
|
|
||||||
extractdirname(path, file);
|
if(not fexist(file)) {
|
||||||
|
extractdirname(path, file);
|
||||||
|
AddBackslash(path);
|
||||||
|
strxmerge(file, sizeof(Path), path, "ctrl/msgs.cnf", NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(fexist(file)) {
|
||||||
|
Path ctrl;
|
||||||
|
extractdirname(ctrl, file);
|
||||||
|
size_t len = strlen(ctrl);
|
||||||
|
if((len > 0) and isslash(ctrl[len - 1])) {
|
||||||
|
ctrl[len - 1] = NUL;
|
||||||
|
extractdirname(path, ctrl);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
strcpy(path, ctrl);
|
||||||
|
}
|
||||||
|
AddBackslash(path);
|
||||||
|
strxcat(path, "data/subs/", sizeof(Path));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
*path = NUL;
|
||||||
|
}
|
||||||
|
|
||||||
FILE* in = fsopen(file, "rb", sharemode);
|
FILE* in = fsopen(file, "rb", sharemode);
|
||||||
if(in) {
|
if(in) {
|
||||||
@ -88,7 +110,7 @@ void gareafile::ReadSynchronet(char* tag) {
|
|||||||
break;
|
break;
|
||||||
AreaCfg aa;
|
AreaCfg aa;
|
||||||
aa.reset();
|
aa.reset();
|
||||||
aa.type = GMB_ECHO;
|
aa.type = (sub_misc & SUB_QNET) ? GMB_LOCAL : GMB_ECHO;
|
||||||
aa.attr = attribsecho;
|
aa.attr = attribsecho;
|
||||||
aa.msgbase = GMB_SMB;
|
aa.msgbase = GMB_SMB;
|
||||||
aa.setechoid((sub.misc & SUB_FIDO) ? sub.sname : sub.code);
|
aa.setechoid((sub.misc & SUB_FIDO) ? sub.sname : sub.code);
|
||||||
|
Reference in New Issue
Block a user