From 36cdbd9d0858355b03e982a330fa0f0c04ac846c Mon Sep 17 00:00:00 2001 From: Serge Gautherie Date: Sat, 9 Aug 2008 04:36:52 +0200 Subject: [PATCH] =?UTF-8?q?Bug=20410708=20=E2=80=93=20Compiler=20warning?= =?UTF-8?q?=20in=20nsUTF8Utils.h=20(Av2)=20Use=20char=20notation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- xpcom/string/public/nsUTF8Utils.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/xpcom/string/public/nsUTF8Utils.h b/xpcom/string/public/nsUTF8Utils.h index 8071860d741..be73a9ed067 100644 --- a/xpcom/string/public/nsUTF8Utils.h +++ b/xpcom/string/public/nsUTF8Utils.h @@ -576,9 +576,9 @@ class ConvertUTF16toUTF8 // Treat broken characters as the Unicode // replacement character 0xFFFD (0xEFBFBD in // UTF-8) - *out++ = 0xEF; - *out++ = 0xBF; - *out++ = 0xBD; + *out++ = '\xEF'; + *out++ = '\xBF'; + *out++ = '\xBD'; NS_WARNING("String ending in half a surrogate pair!"); @@ -603,9 +603,9 @@ class ConvertUTF16toUTF8 // Treat broken characters as the Unicode // replacement character 0xFFFD (0xEFBFBD in // UTF-8) - *out++ = 0xEF; - *out++ = 0xBF; - *out++ = 0xBD; + *out++ = '\xEF'; + *out++ = '\xBF'; + *out++ = '\xBD'; // The pointer to the next character points to the second // 16-bit value, not beyond it, as per Unicode 5.0.0 @@ -623,9 +623,9 @@ class ConvertUTF16toUTF8 { // Treat broken characters as the Unicode replacement // character 0xFFFD (0xEFBFBD in UTF-8) - *out++ = 0xEF; - *out++ = 0xBF; - *out++ = 0xBD; + *out++ = '\xEF'; + *out++ = '\xBF'; + *out++ = '\xBD'; // DC00- DFFF - Low Surrogate NS_WARNING("got a low Surrogate but no high surrogate");