[Scummvm-cvs-logs] SF.net SVN: scummvm:[39369] scummvm/trunk/engines/sci/engine/kstring.cpp

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Fri Mar 13 08:56:06 CET 2009


Revision: 39369
          http://scummvm.svn.sourceforge.net/scummvm/?rev=39369&view=rev
Author:   thebluegr
Date:     2009-03-13 07:56:06 +0000 (Fri, 13 Mar 2009)

Log Message:
-----------
Added an explanatory comment for commit #39368

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kstring.cpp

Modified: scummvm/trunk/engines/sci/engine/kstring.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kstring.cpp	2009-03-13 01:36:07 UTC (rev 39368)
+++ scummvm/trunk/engines/sci/engine/kstring.cpp	2009-03-13 07:56:06 UTC (rev 39369)
@@ -414,6 +414,10 @@
 	if (len == 0) return 1;
 
 	while (*str) {
+		// We're ANDing the string with 0xFF to prevent a situation
+		// where MSVC could sometimes falsely parse the character as
+		// multibyte/Unicode, thereby overflowing an assertion inside
+		// isprint(). This occurs after the intro of LSL5, for example.
 		if (isprint((*str & 0xFF))) printable++;
 		str++;
 	}


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