summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorArmin Le Grand <alg@apache.org>2012-07-18 11:11:48 +0000
committerArmin Le Grand <alg@apache.org>2012-07-18 11:11:48 +0000
commit0132f35e8be61d34156ef907adb7eb98902509da (patch)
treeadf85281f6cf25827e7d27493522555118a3bcfb /cui
parentba86cf07673ed3dde1b4d54242005a4a903d86c9 (diff)
basic, cui, extensions, filter, vcl: fix some warnings
Patch by: Michael Stahl
Notes
Diffstat (limited to 'cui')
-rw-r--r--cui/source/options/opthtml.cxx4
-rw-r--r--cui/source/tabpages/numpages.cxx6
2 files changed, 9 insertions, 1 deletions
diff --git a/cui/source/options/opthtml.cxx b/cui/source/options/opthtml.cxx
index 1aefdc9e9699..29aa1bfe2ce1 100644
--- a/cui/source/options/opthtml.cxx
+++ b/cui/source/options/opthtml.cxx
@@ -198,7 +198,9 @@ void OfaHtmlTabPage::Reset( const SfxItemSet& )
aIgnoreFontNamesCB.Check(pHtmlOpt->IsIgnoreFontFamily());
sal_uInt16 nExport = pHtmlOpt->GetExportMode();
if( nExport >= ( sizeof( aExportToPosArr ) / sizeof( sal_uInt16 ) ) )
- nExport = 4; // default for bad config entry is NS 4.0
+ {
+ nExport = 3; // default for bad config entry is NS 4.0
+ }
sal_uInt16 nPosArr = aExportToPosArr[ nExport ];
// if( nPosArr == DEPRECATED_ENTRY )
// nPosArr = aExportToPosArr[ 4 ]; // again: NS 4.0 is default
diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx
index 3f0f8d4bbba3..9e9219c24acd 100644
--- a/cui/source/tabpages/numpages.cxx
+++ b/cui/source/tabpages/numpages.cxx
@@ -3247,6 +3247,12 @@ void SvxNumPositionTabPage::InitControls()
nMask <<= 1;
}
+ if (SVX_MAX_NUM <= nLvl)
+ {
+ OSL_ENSURE(false, "cannot happen.");
+ return;
+ }
+
if(bSameDistBorderNum)
{
long nDistBorderNum;