[Bf-blender-cvs] [1a0fed9] master: More fix for this stupid uppercase-to-lowercase convertion code... Thanks to Lockal for noting this!

Bastien Montagne noreply at git.blender.org
Sat Nov 16 15:33:44 CET 2013


Commit: 1a0fed9ee08e4499c7a5652f1519a73a290e2962
Author: Bastien Montagne
Date:   Sat Nov 16 15:31:00 2013 +0100
http://developer.blender.org/rB1a0fed9ee08e4499c7a5652f1519a73a290e2962

More fix for this stupid uppercase-to-lowercase convertion code... Thanks to Lockal for noting this!

===================================================================

M	source/blender/blenkernel/intern/unit.c

===================================================================

diff --git a/source/blender/blenkernel/intern/unit.c b/source/blender/blenkernel/intern/unit.c
index 4b6ac82..6447054 100644
--- a/source/blender/blenkernel/intern/unit.c
+++ b/source/blender/blenkernel/intern/unit.c
@@ -609,7 +609,7 @@ int bUnit_ReplaceString(char *str, int len_max, const char *str_prev, double sca
 		int i;
 		char *ch = str;
 
-		for (i = 0; (i < len_max || *ch != '\0'); i++, ch++) {
+		for (i = 0; (i < len_max) && (*ch != '\0'); i++, ch++) {
 			if ((*ch >= 'A') && (*ch <= 'Z'))
 				*ch += ('a' - 'A');
 		}




More information about the Bf-blender-cvs mailing list