diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-02-11 12:32:24 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-02-11 14:33:33 +0000 |
commit | d3ef7f5e3fc2b650020c290386749422bfc07666 (patch) | |
tree | b4f654921943363bd201e058967780d69c9e54f1 /i18npool | |
parent | 83e979f61b02373fc0d624a96347acfad3c64e24 (diff) |
coverity#707927 Uninitialized pointer field
Change-Id: I5011c4dfea02c8fab8ca3ee08bbed7f31396e3ec
Diffstat (limited to 'i18npool')
-rw-r--r-- | i18npool/inc/textconversion.hxx | 5 | ||||
-rw-r--r-- | i18npool/source/textconversion/textconversion.cxx | 3 | ||||
-rw-r--r-- | i18npool/source/textconversion/textconversion_ko.cxx | 3 | ||||
-rw-r--r-- | i18npool/source/textconversion/textconversion_zh.cxx | 3 |
4 files changed, 7 insertions, 7 deletions
diff --git a/i18npool/inc/textconversion.hxx b/i18npool/inc/textconversion.hxx index 42f91bf62cbd..7be157b31899 100644 --- a/i18npool/inc/textconversion.hxx +++ b/i18npool/inc/textconversion.hxx @@ -40,7 +40,7 @@ class TextConversion: public cppu::WeakImplHelper2 > { public: - TextConversion(); + TextConversion(const char* pImplName); ~TextConversion(); // Methods virtual com::sun::star::i18n::TextConversionResult SAL_CALL @@ -81,8 +81,9 @@ public: com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( com::sun::star::uno::RuntimeException ); -protected : +private: const sal_Char* implementationName; +protected : #ifndef DISABLE_DYNLOADING oslModule hModule; oslGenericFunction SAL_CALL getFunctionBySymbol(const sal_Char* func); diff --git a/i18npool/source/textconversion/textconversion.cxx b/i18npool/source/textconversion/textconversion.cxx index fbde6f16efee..2f44cf2ab23a 100644 --- a/i18npool/source/textconversion/textconversion.cxx +++ b/i18npool/source/textconversion/textconversion.cxx @@ -31,7 +31,8 @@ extern "C" { static void SAL_CALL thisModule() {} } #endif -TextConversion::TextConversion() +TextConversion::TextConversion(const char *pImplName) + : implementationName(pImplName) { #ifndef DISABLE_DYNLOADING #ifdef SAL_DLLPREFIX diff --git a/i18npool/source/textconversion/textconversion_ko.cxx b/i18npool/source/textconversion/textconversion_ko.cxx index 617ff29f0dad..2fcc9f7ed091 100644 --- a/i18npool/source/textconversion/textconversion_ko.cxx +++ b/i18npool/source/textconversion/textconversion_ko.cxx @@ -40,6 +40,7 @@ namespace com { namespace sun { namespace star { namespace i18n { #define SCRIPT_HANGUL 2 TextConversion_ko::TextConversion_ko( const Reference < XComponentContext >& xContext ) + : TextConversion("com.sun.star.i18n.TextConversion_ko") { Reference < XInterface > xI; @@ -76,8 +77,6 @@ TextConversion_ko::TextConversion_ko( const Reference < XComponentContext >& xCo maxLeftLength = xCD->getMaxCharCount(ConversionDirection_FROM_LEFT); maxRightLength = xCD->getMaxCharCount(ConversionDirection_FROM_RIGHT); } - - implementationName = "com.sun.star.i18n.TextConversion_ko"; } sal_Int16 SAL_CALL checkScriptType(sal_Unicode c) diff --git a/i18npool/source/textconversion/textconversion_zh.cxx b/i18npool/source/textconversion/textconversion_zh.cxx index 1cbd3b3934e8..8db111856c4b 100644 --- a/i18npool/source/textconversion/textconversion_zh.cxx +++ b/i18npool/source/textconversion/textconversion_zh.cxx @@ -36,10 +36,9 @@ using namespace com::sun::star::uno; namespace com { namespace sun { namespace star { namespace i18n { TextConversion_zh::TextConversion_zh( const Reference < XComponentContext >& xContext ) + : TextConversion("com.sun.star.i18n.TextConversion_zh") { xCDL = ConversionDictionaryList::create(xContext); - - implementationName = "com.sun.star.i18n.TextConversion_zh"; } sal_Unicode SAL_CALL getOneCharConversion(sal_Unicode ch, const sal_Unicode* Data, const sal_uInt16* Index) |