summaryrefslogtreecommitdiff
path: root/src/common/util.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2005-09-08 18:33:51 +0000
committerNick Mathewson <nickm@torproject.org>2005-09-08 18:33:51 +0000
commitc4b3bf06c64712aa83ae13b617fc3e48933945cf (patch)
treed0159cddc32118f91e84c6e56eb92e18d8721d2c /src/common/util.c
parent810572a5de43e9262c6e9c8d68b29fc8d2e70e47 (diff)
downloadtor-c4b3bf06c64712aa83ae13b617fc3e48933945cf.tar.gz
tor-c4b3bf06c64712aa83ae13b617fc3e48933945cf.zip
add strupper function
svn:r4934
Diffstat (limited to 'src/common/util.c')
-rw-r--r--src/common/util.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/common/util.c b/src/common/util.c
index 67d62aeddb..8f908fdf4e 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -299,6 +299,16 @@ void tor_strlower(char *s)
}
}
+/** Convert all alphabetic characters in the nul-terminated string <b>s</b> to
+ * lowercase. */
+void tor_strupper(char *s)
+{
+ while (*s) {
+ *s = toupper(*s);
+ ++s;
+ }
+}
+
/* Compares the first strlen(s2) characters of s1 with s2. Returns as for
* strcmp.
*/