[Scummvm-cvs-logs] SF.net SVN: scummvm:[35185] scummvm/trunk/engines/parallaction/parser.cpp

eriktorbjorn at users.sourceforge.net eriktorbjorn at users.sourceforge.net
Sun Nov 30 11:11:41 CET 2008


Revision: 35185
          http://scummvm.svn.sourceforge.net/scummvm/?rev=35185&view=rev
Author:   eriktorbjorn
Date:     2008-11-30 10:11:38 +0000 (Sun, 30 Nov 2008)

Log Message:
-----------
It's unnecessary to use strlen() just to find out if a string is empty or not.

Modified Paths:
--------------
    scummvm/trunk/engines/parallaction/parser.cpp

Modified: scummvm/trunk/engines/parallaction/parser.cpp
===================================================================
--- scummvm/trunk/engines/parallaction/parser.cpp	2008-11-30 05:32:05 UTC (rev 35184)
+++ scummvm/trunk/engines/parallaction/parser.cpp	2008-11-30 10:11:38 UTC (rev 35185)
@@ -201,7 +201,7 @@
 	}
 
 	clearTokens();
-	while (strlen(line) > 0 && _numTokens < MAX_TOKENS) {
+	while (*line && _numTokens < MAX_TOKENS) {
 		line = parseNextToken(line, _tokens[_numTokens], MAX_TOKEN_LEN, " ");
 		line = Common::ltrim(line);
 		_numTokens++;


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