Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenlib/intern/string.c')
-rw-r--r--source/blender/blenlib/intern/string.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenlib/intern/string.c b/source/blender/blenlib/intern/string.c
index 572b142d044..0ce40f717d4 100644
--- a/source/blender/blenlib/intern/string.c
+++ b/source/blender/blenlib/intern/string.c
@@ -582,7 +582,7 @@ void BLI_ascii_strtolower(char *str, const size_t len)
{
size_t i;
- for (i = 0; i < len; i++)
+ for (i = 0; (i < len) && str[i]; i++)
if (str[i] >= 'A' && str[i] <= 'Z')
str[i] += 'a' - 'A';
}
@@ -591,7 +591,7 @@ void BLI_ascii_strtoupper(char *str, const size_t len)
{
size_t i;
- for (i = 0; i < len; i++)
+ for (i = 0; (i < len) && str[i]; i++)
if (str[i] >= 'a' && str[i] <= 'z')
str[i] -= 'a' - 'A';
}