[Libreoffice-commits] core.git: 11 commits - sc/source starmath/source svx/source sw/source test/source

Caolán McNamara caolanm at redhat.com
Fri Mar 28 02:25:42 PDT 2014


 sc/source/filter/lotus/lotattr.cxx         |    1 -
 sc/source/filter/lotus/tool.cxx            |    8 --------
 sc/source/filter/oox/workbookfragment.cxx  |    5 +++--
 starmath/source/node.cxx                   |    3 ---
 svx/source/dialog/paraprev.cxx             |    1 -
 sw/source/filter/basflt/shellio.cxx        |    3 ---
 sw/source/ui/vba/vbalisthelper.cxx         |   16 ----------------
 test/source/sheet/xdatapilotdescriptor.cxx |    2 --
 8 files changed, 3 insertions(+), 36 deletions(-)

New commits:
commit 56d58ad8be2f8367b5a42d7832710e4e07e20cad
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:20:09 2014 +0000

    coverity#735461 Dead default in switch
    
    Change-Id: Icc6763acdd7d7fb2526d8cf2c1142e7ed34efc8f

diff --git a/sc/source/filter/lotus/lotattr.cxx b/sc/source/filter/lotus/lotattr.cxx
index cdc804a..65f5d46 100644
--- a/sc/source/filter/lotus/lotattr.cxx
+++ b/sc/source/filter/lotus/lotattr.cxx
@@ -163,7 +163,6 @@ void LotAttrCache::LotusToScBorderLine( sal_uInt8 nLine, ::editeng::SvxBorderLin
 
     switch ( nLine )
     {
-        default:
         case 0: aBL.SetBorderLineStyle(table::BorderLineStyle::NONE); break;
         case 1: aBL.SetWidth( DEF_LINE_WIDTH_1 ); break;
         case 2: aBL.SetWidth( DEF_LINE_WIDTH_2 ); break;
commit 28784e2df9b27de8e8f5390b5c976f5b80cf2786
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:17:16 2014 +0000

    coverity#735462 Dead default in switch
    
    Change-Id: I48bc819b939ae1a436d3103e8fc75c69c2324dc8

diff --git a/sc/source/filter/lotus/tool.cxx b/sc/source/filter/lotus/tool.cxx
index f4f2dad..228f0fc 100644
--- a/sc/source/filter/lotus/tool.cxx
+++ b/sc/source/filter/lotus/tool.cxx
@@ -337,14 +337,6 @@ SfxUInt32Item* FormCache::NewAttr( sal_uInt8 nFormat, sal_uInt8 nSt )
                     break;
             }
             break;
-        default:
-            //fStandard;nL;
-            nIndex1 = pFormTable->GetStandardFormat(
-                NUMBERFORMAT_NUMBER, eLanguage );
-            aFormString = pFormTable->GenerateFormat(nIndex1,
-                eLanguage, false, false, nL, 1);
-            nIndex1 = 0;
-            break;
     }
 
     // Format in Table schieben
commit bdda683ed7e0db5dce14e39215eba198523aae70
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:15:55 2014 +0000

    coverity#735463 Dead default in switch
    
    Change-Id: I422f11f1ccda36c00e00775b32772c1e827b6686

diff --git a/sc/source/filter/oox/workbookfragment.cxx b/sc/source/filter/oox/workbookfragment.cxx
index 170348f..69a9c90 100644
--- a/sc/source/filter/oox/workbookfragment.cxx
+++ b/sc/source/filter/oox/workbookfragment.cxx
@@ -444,8 +444,9 @@ void WorkbookFragment::finalizeImport()
                             case SHEETTYPE_CHARTSHEET:
                                 xFragment.set( new ChartsheetFragment( *xSheetGlob, aFragmentPath ) );
                             break;
-                            default:
-                                OSL_ENSURE( false, "WorkbookFragment::finalizeImport - unexpected sheet type" );
+                            case SHEETTYPE_EMPTYSHEET:
+                            case SHEETTYPE_MODULESHEET:
+                                break;
                         }
 
                         // insert the fragment into the map
commit 722c82b018327c1f9578ddc533ebbb06080848eb
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:13:51 2014 +0000

    coverity#735496 Dead default in switch
    
    Change-Id: I5eddf8be2a98aa57fdcdf44d390def6522caa25d

diff --git a/starmath/source/node.cxx b/starmath/source/node.cxx
index 75d7529..9a6ea0c 100644
--- a/starmath/source/node.cxx
+++ b/starmath/source/node.cxx
@@ -1635,9 +1635,6 @@ void SmSubSupNode::Arrange(const OutputDevice &rDev, const SmFormat &rFormat)
                                 RHA_CENTER, RVA_BASELINE);
                 aPos.Y() -= nDist;
                 break;
-            default :
-                SAL_WARN("starmath", "unknown case");
-                break;
         }
 
         pSubSup->MoveTo(aPos);
commit e1b8f3f6c5e34e1c43a19e5965b847bfad13d02f
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:08:30 2014 +0000

    coverity#735554 Dead default in switch
    
    Change-Id: I12ebe5b9018109f35b6c6691fcf4497c56850d7c

diff --git a/test/source/sheet/xdatapilotdescriptor.cxx b/test/source/sheet/xdatapilotdescriptor.cxx
index 1e2c67a..be968e4 100644
--- a/test/source/sheet/xdatapilotdescriptor.cxx
+++ b/test/source/sheet/xdatapilotdescriptor.cxx
@@ -130,8 +130,6 @@ void XDataPilotDescriptor::testGetDataPilotFields_Impl( uno::Reference< sheet::X
                     xPropSet->setPropertyValue(aOrientation, aAny);
                 }
                 break;
-            default:
-                break;
         }
     }
 }
commit 308daa42c0935426c177c73d578fa2961a661171
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:04:50 2014 +0000

    coverity#735506 Dead default in switch
    
    Change-Id: Idb2ec83617622805a6e02662f2bc17faf38575ea

diff --git a/svx/source/dialog/paraprev.cxx b/svx/source/dialog/paraprev.cxx
index edce422..d31e5b9 100644
--- a/svx/source/dialog/paraprev.cxx
+++ b/svx/source/dialog/paraprev.cxx
@@ -147,7 +147,6 @@ void SvxParaPrevWindow::DrawParagraph( bool bAll )
             long nLW;
             switch( i )
             {
-                default:
                 case 3: nLW = aLineSiz.Width() * 8 / 10;    break;
                 case 4: nLW = aLineSiz.Width() * 9 / 10;    break;
                 case 5: nLW = aLineSiz.Width() / 2;         break;
commit 428dcc9c17118e791fb29d5b82fc317e598bb320
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:03:48 2014 +0000

    coverity#735529 Dead default in switch
    
    Change-Id: I8423ab78c711065371b9c3c5abeabbb174a57faf

diff --git a/sw/source/filter/basflt/shellio.cxx b/sw/source/filter/basflt/shellio.cxx
index ed6e51a..56eefcb 100644
--- a/sw/source/filter/basflt/shellio.cxx
+++ b/sw/source/filter/basflt/shellio.cxx
@@ -622,9 +622,6 @@ void Reader::ResetFrmFmts( SwDoc& rDoc )
         sal_uInt16 nPoolId;
         switch (i)
         {
-            default:
-                OSL_ENSURE(i == 0, "Impossible");
-                //fallthrough
             case 0:
                 nPoolId = RES_POOLFRM_FRAME;
                 break;
commit 460262591311487cf45f9d92b1f7106b90c66e96
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:02:56 2014 +0000

    coverity#735550 Dead default in switch
    
    Change-Id: I730b12aa971757e70d7df7b9cd4ec9c67fb4468e

diff --git a/sw/source/ui/vba/vbalisthelper.cxx b/sw/source/ui/vba/vbalisthelper.cxx
index 87d7026..5b5fca7 100644
--- a/sw/source/ui/vba/vbalisthelper.cxx
+++ b/sw/source/ui/vba/vbalisthelper.cxx
@@ -371,10 +371,6 @@ void SwVbaListHelper::CreateOutlineNumberForType1() throw( css::uno::RuntimeExce
                 sSuffix = OUString( '.' );
                 break;
             }
-            default:
-            {
-                throw uno::RuntimeException();
-            }
         }
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_NUMBERING_TYPE ), uno::makeAny( nNumberingType ) );
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_PREFIX ), uno::makeAny( sPrefix ) );
commit 220c918ebe13fef0839b765a3091d9641849dc1b
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:02:33 2014 +0000

    coverity#735553 Dead default in switch
    
    Change-Id: If3a6f5bda7c106a8d66fe2486f9e3d1f462223c4

diff --git a/sw/source/ui/vba/vbalisthelper.cxx b/sw/source/ui/vba/vbalisthelper.cxx
index a423787..87d7026 100644
--- a/sw/source/ui/vba/vbalisthelper.cxx
+++ b/sw/source/ui/vba/vbalisthelper.cxx
@@ -632,10 +632,6 @@ void SwVbaListHelper::CreateOutlineNumberForType6() throw( css::uno::RuntimeExce
                 sSuffix = OUString( '.' );
                 break;
             }
-            default:
-            {
-                throw uno::RuntimeException();
-            }
         }
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_NUMBERING_TYPE ), uno::makeAny( nNumberingType ) );
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_PREFIX ), uno::makeAny( sPrefix ) );
commit db3c74d4e0c95b4b531235469e75fab9e3ed1a9b
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 11:02:14 2014 +0000

    coverity#735552 Dead default in switch
    
    Change-Id: Ifcf9c204ba7cf4b7fb9210781664b1b4a785c82e

diff --git a/sw/source/ui/vba/vbalisthelper.cxx b/sw/source/ui/vba/vbalisthelper.cxx
index 5966078..a423787 100644
--- a/sw/source/ui/vba/vbalisthelper.cxx
+++ b/sw/source/ui/vba/vbalisthelper.cxx
@@ -530,10 +530,6 @@ void SwVbaListHelper::CreateOutlineNumberForType4() throw( css::uno::RuntimeExce
                 sSuffix = OUString( '.' );
                 break;
             }
-            default:
-            {
-                throw uno::RuntimeException();
-            }
         }
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_NUMBERING_TYPE ), uno::makeAny( nNumberingType ) );
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_PREFIX ), uno::makeAny( sPrefix ) );
commit b443fe81a720d59ee7a9b229adaebd3f683cfa06
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 27 10:58:08 2014 +0000

    coverity#735551 Dead default in switch
    
    Change-Id: I524a81cf1b617c63a5c5a5ab3b49145d6d5e75ff

diff --git a/sw/source/ui/vba/vbalisthelper.cxx b/sw/source/ui/vba/vbalisthelper.cxx
index b600e41..5966078 100644
--- a/sw/source/ui/vba/vbalisthelper.cxx
+++ b/sw/source/ui/vba/vbalisthelper.cxx
@@ -447,10 +447,6 @@ void SwVbaListHelper::CreateOutlineNumberForType3() throw( css::uno::RuntimeExce
                 aBulletChar = OUString( sal_Unicode( CHAR_DIAMOND ) );
                 break;
             }
-            default:
-            {
-                throw uno::RuntimeException();
-            }
         }
         setOrAppendPropertyValue( aPropertyValues, OUString(UNO_NAME_BULLET_CHAR ), uno::makeAny( aBulletChar ) );
         mxNumberingRules->replaceByIndex( nLevel, uno::makeAny( aPropertyValues ) );


More information about the Libreoffice-commits mailing list