summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1997-12-03 02:27:50 +0000
committerAndrew Tridgell <tridge@samba.org>1997-12-03 02:27:50 +0000
commit3e23d79cfe2ff42a21b97ba367f76f50bd6af45c (patch)
tree69519344e2c8268ef411214dc77f3c7f1e248b50
parent1463cb1a43967c099d5031794ffcfbcccdff6abe (diff)
downloadsamba-3e23d79cfe2ff42a21b97ba367f76f50bd6af45c.tar.gz
samba-3e23d79cfe2ff42a21b97ba367f76f50bd6af45c.tar.bz2
samba-3e23d79cfe2ff42a21b97ba367f76f50bd6af45c.zip
fix toupper(c) on a already uppercase char and tolower(c) on an
already lowercase char when using code pages. Jeremy, can you confirm that this looks right? It comes from PR#1992 (This used to be commit 157fde339695d3185ecf857187e981edd06a8b65)
-rw-r--r--source3/lib/charset.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/lib/charset.c b/source3/lib/charset.c
index 4869e09fec..217f407b9e 100644
--- a/source3/lib/charset.c
+++ b/source3/lib/charset.c
@@ -132,6 +132,8 @@ static void add_dos_char(int lower, BOOL map_lower_to_upper,
map_upper_to_lower ? "True" : "False"));
if (lower) dos_char_map[lower] = 1;
if (upper) dos_char_map[upper] = 1;
+ lower_char_map[lower] = (char)lower; /* Define tolower(lower) */
+ upper_char_map[upper] = (char)upper; /* Define toupper(upper) */
if (lower && upper) {
if(map_upper_to_lower)
lower_char_map[upper] = (char)lower;