Changeset 1007 for Daodan/src/Daodan_Config.c
- Timestamp:
- Jul 4, 2014, 5:42:25 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Daodan/src/Daodan_Config.c
r1000 r1007 19 19 static const char* defaultSection = "options"; 20 20 21 static char invalidCurParamaters[ 1000] = "";22 static char invalidTotalParamaters[ 3000] = "";21 static char invalidCurParamaters[2000] = ""; 22 static char invalidTotalParamaters[4000] = ""; 23 23 24 24 void DDrConfig_PrintHelp(); … … 531 531 } 532 532 } else { 533 char buf[ 50];533 char buf[100]; 534 534 if (!_stricmp(section, "*")) 535 sprintf _s(buf, sizeof(buf), " %s\n", name);535 sprintf(buf, " %s\n", name); 536 536 else 537 sprintf _s(buf, sizeof(buf), " %s.%s\n", section, name);537 sprintf(buf, " %s.%s\n", section, name); 538 538 if (strlen(buf) + strlen(invalidCurParamaters) < sizeof(invalidCurParamaters) - 1) { 539 539 strcpy(invalidCurParamaters + strlen(invalidCurParamaters), buf); … … 593 593 if (strlen(invalidCurParamaters) > 0) 594 594 { 595 sprintf _s(invalidTotalParamaters, sizeof(invalidTotalParamaters), "In %s:\n%s\n", iniName, invalidCurParamaters);595 sprintf(invalidTotalParamaters, "In %s:\n%s\n", iniName, invalidCurParamaters); 596 596 invalidCurParamaters[0] = 0; 597 597 } … … 603 603 if (strlen(invalidCurParamaters) > 0) 604 604 { 605 sprintf _s(invalidTotalParamaters, sizeof(invalidTotalParamaters), "%sOn command line:\n%s\n", invalidTotalParamaters, invalidCurParamaters);605 sprintf(invalidTotalParamaters, "%sOn command line:\n%s\n", invalidTotalParamaters, invalidCurParamaters); 606 606 } 607 607 608 608 if (strlen(invalidTotalParamaters) > 0) 609 609 { 610 char msg[ 3200];611 sprintf _s(msg, sizeof(msg), "Invalid parameters given:\n%sContinue launching Oni?", invalidTotalParamaters);610 char msg[4096]; 611 sprintf(msg, "Invalid parameters given:\n%sContinue launching Oni?", invalidTotalParamaters); 612 612 int res = MessageBox(NULL, msg, "Parameters invalid", MB_ICONWARNING | MB_YESNO | MB_DEFBUTTON1); 613 613 if (res == IDNO) {
Note:
See TracChangeset
for help on using the changeset viewer.