summaryrefslogtreecommitdiff
path: root/mysys/mf_casecnv.c
diff options
context:
space:
mode:
Diffstat (limited to 'mysys/mf_casecnv.c')
-rw-r--r--mysys/mf_casecnv.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/mysys/mf_casecnv.c b/mysys/mf_casecnv.c
index 0302688ad1f..1fae3aead32 100644
--- a/mysys/mf_casecnv.c
+++ b/mysys/mf_casecnv.c
@@ -45,8 +45,11 @@ void caseup_str(my_string str)
}
else
#endif
- while ((*str = toupper(*str)) != 0)
+ while (*str!=0) /* iterate till the end of string */
+ {
+ *str= toupper(*str);
str++;
+ }
} /* caseup_str */
/* string to lowercase */
@@ -66,8 +69,11 @@ void casedn_str(my_string str)
}
else
#endif
- while ((*str= tolower(*str)) != 0)
+ while (*str!=0) /* iterate till the end of string */
+ {
+ *str= tolower(*str);
str++;
+ }
} /* casedn_str */