[Libreoffice-commits] .: sal/textenc
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Nov 26 03:08:23 PST 2012
sal/textenc/tables.cxx | 8 ++++++++
1 file changed, 8 insertions(+)
New commits:
commit 86b966257e63d4dbae1eb43aa16730a61811299c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Nov 26 11:05:31 2012 +0000
removal of ISCII code left a bogus hole in table
Change-Id: I341e36a59172116c9f90c67c6ab23d9e4f2c5847
diff --git a/sal/textenc/tables.cxx b/sal/textenc/tables.cxx
index ebea916..7400abb 100644
--- a/sal/textenc/tables.cxx
+++ b/sal/textenc/tables.cxx
@@ -22,6 +22,8 @@
#include <cassert>
#include <cstddef>
+#include <boost/static_assert.hpp>
+
#include "rtl/textenc.h"
#include "sal/types.h"
@@ -206,11 +208,17 @@ extern "C" SAL_DLLPUBLIC_EXPORT ImplTextEncodingData const *
&aImplBig5HkscsTextEncodingData, /* BIG5_HKSCS */
&aImplTis620TextEncodingData, /* TIS_620 */
&aImplKoi8UTextEncodingData, /* KOI8_U */
+ NULL, /* TODO! ISCII_DEVANAGARI */
NULL, /* JAVA_UTF8, see above */
&adobeStandardEncodingData, /* ADOBE_STANDARD */
&adobeSymbolEncodingData, /* ADOBE_SYMBOL */
&aImplPT154TextEncodingData, /* PT154 */
&adobeDingbatsEncodingData }; /* ADOBE_DINGBATS */
+
+ //update table above if a new encoding is added
+ BOOST_STATIC_ASSERT(
+ SAL_N_ELEMENTS(aData) == RTL_TEXTENCODING_ADOBE_DINGBATS + 1);
+
return
nEncoding < SAL_N_ELEMENTS(aData) ? aData[nEncoding] : NULL;
}
More information about the Libreoffice-commits
mailing list