summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2011-07-19 13:35:45 -0700
committerJeremy Allison <jra@samba.org>2011-07-19 23:48:05 +0200
commit93dcfdea389098fd802cc4f5be8d5d578454d624 (patch)
treebd7b211fa51d285dcd0605483e99db5d2ef9f948 /source3
parentee34c25c8a989b5a7c0ad59d71bb39f8efff045c (diff)
downloadsamba-93dcfdea389098fd802cc4f5be8d5d578454d624.tar.gz
samba-93dcfdea389098fd802cc4f5be8d5d578454d624.tar.bz2
samba-93dcfdea389098fd802cc4f5be8d5d578454d624.zip
Second part of fix for bug 8310 - toupper_ascii() is broken on big-endian systems.
Re-add: smb_ucs2_t toupper_w(smb_ucs2_t v); and ensure it is called whenever we are operating on smb_ucs2_t variables. I'd like to make the definition of smb_ucs2_t incompatible with int and codepoint_t so they can't be mixed, but that's a patch for another time. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Tue Jul 19 23:48:05 CEST 2011 on sn-devel-104
Diffstat (limited to 'source3')
-rw-r--r--source3/lib/charcnv.c2
-rw-r--r--source3/lib/ms_fnmatch.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/source3/lib/charcnv.c b/source3/lib/charcnv.c
index 17e836dfe0..7d7058cbb0 100644
--- a/source3/lib/charcnv.c
+++ b/source3/lib/charcnv.c
@@ -287,7 +287,7 @@ static size_t push_ucs2(const void *base_ptr, void *dest, const char *src, size_
terminated if STR_TERMINATE isn't set. */
for (i = 0; i < (ret / 2) && i < (dest_len / 2) && dest_ucs2[i]; i++) {
- smb_ucs2_t v = toupper_m(dest_ucs2[i]);
+ smb_ucs2_t v = toupper_w(dest_ucs2[i]);
if (v != dest_ucs2[i]) {
dest_ucs2[i] = v;
}
diff --git a/source3/lib/ms_fnmatch.c b/source3/lib/ms_fnmatch.c
index f02354bfd7..e32d094a6b 100644
--- a/source3/lib/ms_fnmatch.c
+++ b/source3/lib/ms_fnmatch.c
@@ -129,7 +129,7 @@ static int ms_fnmatch_core(const smb_ucs2_t *p, const smb_ucs2_t *n,
if (is_case_sensitive) {
return -1;
}
- if (toupper_m(c) != toupper_m(*n)) {
+ if (toupper_w(c) != toupper_w(*n)) {
return -1;
}
}