Fix numerical groups, packed feature
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
// The Goldware Library
|
||||
// Copyright (C) 1999-2000 Alexander S. Aganichev
|
||||
// Copyright (C) 1999-2002 Alexander S. Aganichev
|
||||
// ------------------------------------------------------------------
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Library General Public
|
||||
@@ -217,8 +217,12 @@ void gareafile::ReadCrashmailCfg(const char* file) {
|
||||
unconfirmed = true;
|
||||
break;
|
||||
case CRC_GROUP:
|
||||
if(jbstrcpy(tmp, buf, 100, &jbcpos))
|
||||
aa.groupid = toupper(tmp[0]);
|
||||
if(jbstrcpy(tmp, buf, 100, &jbcpos)) {
|
||||
if(isdigit(tmp[0]))
|
||||
aa.groupid = 0x8000+atoi(tmp);
|
||||
else if(isalpha(tmp[0]))
|
||||
aa.groupid = toupper(tmp[0]);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
// The Goldware Library
|
||||
// Copyright (C) 1999-2000 Alexander S. Aganichev
|
||||
// Copyright (C) 1999-2002 Alexander S. Aganichev
|
||||
// ------------------------------------------------------------------
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Library General Public
|
||||
@@ -301,7 +301,9 @@ void gareafile::ReadHPTFile(char* path, char* file, char* options, char* origin,
|
||||
|
||||
gettok(&key, &val);
|
||||
|
||||
if(isalpha(*key))
|
||||
if(isdigit(*key))
|
||||
aa.groupid = 0x8000+atoi(key);
|
||||
else if(isalpha(*key))
|
||||
aa.groupid = toupper(*key);
|
||||
}
|
||||
else if (strieql(opt, "d")) {
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
// The Goldware Library
|
||||
// Copyright (C) 1999 Alexander S. Aganichev
|
||||
// Copyright (C) 1999, 2002 Alexander S. Aganichev
|
||||
// ------------------------------------------------------------------
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Library General Public
|
||||
@@ -49,7 +49,11 @@ void gareafile::ReadQEchoFile(char* file, char* options, char* origin) {
|
||||
|
||||
char* ptr = strtok(buf, " \t");
|
||||
aa.reset();
|
||||
aa.groupid = atoi(ptr);
|
||||
|
||||
if(isdigit(*ptr))
|
||||
aa.groupid = 0x8000+atoi(ptr);
|
||||
else if(isalpha(*ptr))
|
||||
aa.groupid = toupper(*ptr);
|
||||
|
||||
if((ptr = strtok(NULL, " \t")) != NULL) {
|
||||
if(*ptr == '*') {
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
// ------------------------------------------------------------------
|
||||
// The Goldware Library
|
||||
// Copyright (C) 1999-2000 Alexander S. Aganichev
|
||||
// Copyright (C) 1999-2002 Alexander S. Aganichev
|
||||
// ------------------------------------------------------------------
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Library General Public
|
||||
@@ -139,7 +139,10 @@ void gareafile::ReadSpaceAr(const char* file) {
|
||||
break;
|
||||
}
|
||||
case CRC_GROUP:
|
||||
aa.groupid = toupper(*val);
|
||||
if(isdigit(*val))
|
||||
aa.groupid = 0x8000+atoi(val);
|
||||
else if(isalpha(*val))
|
||||
aa.groupid = toupper(*val);
|
||||
break;
|
||||
case CRC_ENDAREA:
|
||||
if(aa.msgbase)
|
||||
|
@@ -118,8 +118,12 @@ void gareafile::ReadSquishFile(char* path, char* file, char* options, char* orig
|
||||
if(strnieql(p, "-$", 2)) {
|
||||
aa.msgbase = GMB_SQUISH;
|
||||
p += 2;
|
||||
if((tolower(*p) == 'g') and isalpha(p[1]))
|
||||
aa.groupid = toupper(p[1]);
|
||||
if((tolower(*p) == 'g') and isalpha(p[1])) {
|
||||
if(isdigit(p[1]))
|
||||
aa.groupid = 0x8000+atoi(p+1);
|
||||
else if(isalpha(p[1]))
|
||||
aa.groupid = toupper(p[1]);
|
||||
}
|
||||
else if(tolower(*p) == 'n') {
|
||||
key = ++p;
|
||||
getkeyval(&key, &p);
|
||||
|
Reference in New Issue
Block a user