diff options
Diffstat (limited to 'svtools/source/numbers')
-rw-r--r-- | svtools/source/numbers/numfmuno.cxx | 2 | ||||
-rw-r--r-- | svtools/source/numbers/zforscan.cxx | 13 |
2 files changed, 6 insertions, 9 deletions
diff --git a/svtools/source/numbers/numfmuno.cxx b/svtools/source/numbers/numfmuno.cxx index 7417367ec124..d65a2fd696ce 100644 --- a/svtools/source/numbers/numfmuno.cxx +++ b/svtools/source/numbers/numfmuno.cxx @@ -774,7 +774,7 @@ uno::Any SAL_CALL SvNumberFormatObj::getPropertyValue( const rtl::OUString& aPro else if (aString.EqualsAscii( PROPERTYNAME_LOCALE )) { lang::Locale aLocale( MsLangId::convertLanguageToLocale( - pFormat->GetLanguage())); + pFormat->GetLanguage())); aRet <<= aLocale; } else if (aString.EqualsAscii( PROPERTYNAME_TYPE )) diff --git a/svtools/source/numbers/zforscan.cxx b/svtools/source/numbers/zforscan.cxx index d6ce04c4da2a..77b33226559c 100644 --- a/svtools/source/numbers/zforscan.cxx +++ b/svtools/source/numbers/zforscan.cxx @@ -491,6 +491,8 @@ Color* ImpSvNumberformatScan::GetColor(String& sStr) if ( j < NF_MAX_DEFAULT_COLORS ) i = j; } + + Color* pResult = NULL; if (i >= NF_MAX_DEFAULT_COLORS) { const String& rColorWord = pKeyword[NF_KEY_COLOR]; @@ -516,15 +518,9 @@ Color* ImpSvNumberformatScan::GetColor(String& sStr) { long nIndex = sString.ToInt32(); if (nIndex > 0 && nIndex <= 64) - return pFormatter->GetUserDefColor((USHORT)nIndex-1); - else - return NULL; + pResult = pFormatter->GetUserDefColor((USHORT)nIndex-1); } - else - return NULL; } - else - return NULL; } else { @@ -538,8 +534,9 @@ Color* ImpSvNumberformatScan::GetColor(String& sStr) else sStr = pKeyword[NF_KEY_FIRSTCOLOR+i]; - return &(StandardColor[i]); + pResult = &(StandardColor[i]); } + return pResult; } |