diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-11-05 09:20:30 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-11-05 14:57:55 +0000 |
commit | 32ae77e28d98a60c396d274e1e2ff44fe6265a9b (patch) | |
tree | d44384e2942e1e987d95715f11a94d1da0b0ed9a /scaddins | |
parent | 5f15cc01b31ccaed0c6482a36556dece084ce302 (diff) |
coverity#982307 coverity deadcode vs compiler switch warnings
Change-Id: I022d3bbe40058f81cdfc2436cfe70ac2d96382e6
Diffstat (limited to 'scaddins')
-rw-r--r-- | scaddins/source/analysis/analysishelper.cxx | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/scaddins/source/analysis/analysishelper.cxx b/scaddins/source/analysis/analysishelper.cxx index c4a0c542926c..1dc310b01f59 100644 --- a/scaddins/source/analysis/analysishelper.cxx +++ b/scaddins/source/analysis/analysishelper.cxx @@ -598,12 +598,9 @@ double GetYearFrac( sal_Int32 nNullDate, sal_Int32 nStartDate, sal_Int32 nEndDat case 3: // 3=exact/365 nDaysInYear = 365; break; -#ifdef _MSC_VER - // Coverity complains this is dead code, but MSVC thinks nDaysInYear - // is uninitialized if it's missing. + //coverity[dead_error_begin] - condition exists to avoid compiler warning default: throw lang::IllegalArgumentException(); -#endif } return double( nDayDiff ) / nDaysInYear; @@ -931,8 +928,9 @@ bool ParseDouble( const sal_Unicode*& rp, double& rRet ) else eS = S_End; break; - case S_End: // to avoid compiler warning - break; // loop exits anyway + //coverity[dead_error_begin] - condition exists to avoid compiler warning + case S_End: + break; } p++; |