From 6ba9384bc105fe6eb686e81dacb764ee324551ff Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 6 Sep 2010 15:13:48 +0200 Subject: [PATCH] s3: Fix the charset_pull routine In the push routine we do the SVAL, so we should do the SSVAL here. --- lib/util/charset/charset.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lib/util/charset/charset.h b/lib/util/charset/charset.h index 68907aa..bd08f7e 100644 --- a/lib/util/charset/charset.h +++ b/lib/util/charset/charset.h @@ -266,7 +266,7 @@ static size_t CHARSETNAME ## _pull(void *cd, const char **inbuf, size_t *inbytes char **outbuf, size_t *outbytesleft) \ { \ while (*inbytesleft >= 1 && *outbytesleft >= 2) { \ - *(uint16*)(*outbuf) = to_ucs2[((unsigned char*)(*inbuf))[0]]; \ + SSVAL(*outbuf, 0, to_ucs2[((unsigned char*)(*inbuf))[0]]); \ (*inbytesleft) -= 1; \ (*outbytesleft) -= 2; \ (*inbuf) += 1; \ -- 1.7.0.4