[Scummvm-cvs-logs] SF.net SVN: scummvm: [23960] scummvm/trunk

sev at users.sourceforge.net sev at users.sourceforge.net
Thu Sep 21 13:44:56 CEST 2006


Revision: 23960
          http://svn.sourceforge.net/scummvm/?rev=23960&view=rev
Author:   sev
Date:     2006-09-21 04:42:44 -0700 (Thu, 21 Sep 2006)

Log Message:
-----------
Fix bug #1562795: "Bug with auto-generated game IDs"

Modified Paths:
--------------
    scummvm/trunk/NEWS
    scummvm/trunk/gui/launcher.cpp

Modified: scummvm/trunk/NEWS
===================================================================
--- scummvm/trunk/NEWS	2006-09-21 01:36:58 UTC (rev 23959)
+++ scummvm/trunk/NEWS	2006-09-21 11:42:44 UTC (rev 23960)
@@ -20,6 +20,7 @@
 0.9.1 (????-??-??)
  General:
    - Fixed potential garbage and/or crash in debug console.
+   - Removed restriction on 27 games per game id when added via launcher.
 
  SCUMM:
    - Improved support for international versions of HE games.

Modified: scummvm/trunk/gui/launcher.cpp
===================================================================
--- scummvm/trunk/gui/launcher.cpp	2006-09-21 01:36:58 UTC (rev 23959)
+++ scummvm/trunk/gui/launcher.cpp	2006-09-21 11:42:44 UTC (rev 23960)
@@ -649,13 +649,13 @@
 			// are *adding* a game to the config, not replacing).
 			String domain(result.gameid);
 			if (ConfMan.hasGameDomain(domain)) {
-				char suffix = 'a';
-				domain += suffix;
+				int suffixN = 1;
+				char suffix[16];
+
 				while (ConfMan.hasGameDomain(domain)) {
-					assert(suffix < 'z');
-					domain.deleteLastChar();
-					suffix++;
-					domain += suffix;
+					snprintf(suffix, 16, "-%d", suffixN);
+					domain = result.gameid + suffix;
+					suffixN++;
 				}
 			}
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list