summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2006-01-31 18:34:51 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:06:20 -0500
commita2cfc56befc5d6db66f394f750f2f945b746dcb3 (patch)
tree9fc69e871fc132df56735788438d5ffec83429e3 /source3
parent5256cacd3bd4268b96907beaed9f18866063d492 (diff)
downloadsamba-a2cfc56befc5d6db66f394f750f2f945b746dcb3.tar.gz
samba-a2cfc56befc5d6db66f394f750f2f945b746dcb3.tar.bz2
samba-a2cfc56befc5d6db66f394f750f2f945b746dcb3.zip
r13260: Fix stupid bug Volker found for big-endian machines.
Jeremy. (This used to be commit 31903cf25d4075b8518e370b7618de41510f7995)
Diffstat (limited to 'source3')
-rw-r--r--source3/include/smb.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/include/smb.h b/source3/include/smb.h
index fba02565d8..315eb3233a 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -173,7 +173,7 @@ typedef smb_ucs2_t wfstring[FSTRING_LEN];
#define UCS2_CHAR(c) ((c) << UCS2_SHIFT)
/* return an ascii version of a ucs2 character */
-#define UCS2_TO_CHAR(c) ((c) & 0xff)
+#define UCS2_TO_CHAR(c) (((c) >> UCS2_SHIFT) & 0xff)
/* Copy into a smb_ucs2_t from a possibly unaligned buffer. Return the copied smb_ucs2_t */
#define COPY_UCS2_CHAR(dest,src) (((unsigned char *)(dest))[0] = ((unsigned char *)(src))[0],\