coverity#1440239 Uncaught exception

Change-Id: I2b744d70ab426fbf26bcb3762aafaa569d0aafc7
Reviewed-on: https://gerrit.libreoffice.org/61675
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
diff --git a/sc/source/ui/inc/tabview.hxx b/sc/source/ui/inc/tabview.hxx
index 7dfcaea..8ce857b 100644
--- a/sc/source/ui/inc/tabview.hxx
+++ b/sc/source/ui/inc/tabview.hxx
@@ -174,7 +174,7 @@ private:
    std::unique_ptr<ScPageBreakData>  pPageBreakData;
    std::vector<ScHighlightEntry>     maHighlightRanges;

    std::unique_ptr<ScDocument>       pBrushDocument;         // cell formats for format paint brush
    ScDocumentUniquePtr               pBrushDocument;         // cell formats for format paint brush
    std::unique_ptr<SfxItemSet>       pDrawBrushSet;          // drawing object attributes for paint brush

    Timer               aScrollTimer;
@@ -600,7 +600,7 @@ public:
    ScDocument*     GetBrushDocument() const        { return pBrushDocument.get(); }
    SfxItemSet*     GetDrawBrushSet() const         { return pDrawBrushSet.get(); }
    bool            IsPaintBrushLocked() const      { return bLockPaintBrush; }
    void            SetBrushDocument( std::unique_ptr<ScDocument> pNew, bool bLock );
    void            SetBrushDocument( ScDocumentUniquePtr pNew, bool bLock );
    void            SetDrawBrushSet( std::unique_ptr<SfxItemSet> pNew, bool bLock );
    void            ResetBrushDocument();

diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx
index cd52cbd..4b9e14c 100644
--- a/sc/source/ui/view/formatsh.cxx
+++ b/sc/source/ui/view/formatsh.cxx
@@ -2780,7 +2780,7 @@ void ScFormatShell::ExecFormatPaintbrush( const SfxRequest& rReq )
        if ( pViewData->GetSimpleArea(aDummy) != SC_MARK_SIMPLE )
            pView->Unmark();

        std::unique_ptr<ScDocument> pBrushDoc(new ScDocument( SCDOCMODE_CLIP ));
        ScDocumentUniquePtr pBrushDoc(new ScDocument( SCDOCMODE_CLIP ));
        pView->CopyToClip( pBrushDoc.get(), false, true );
        pView->SetBrushDocument( std::move(pBrushDoc), bLock );
    }
diff --git a/sc/source/ui/view/tabview5.cxx b/sc/source/ui/view/tabview5.cxx
index c4e7768..4262c03 100644
--- a/sc/source/ui/view/tabview5.cxx
+++ b/sc/source/ui/view/tabview5.cxx
@@ -616,7 +616,7 @@ void ScTabView::MakeVisible( const tools::Rectangle& rHMMRect )
    }
}

void ScTabView::SetBrushDocument( std::unique_ptr<ScDocument> pNew, bool bLock )
void ScTabView::SetBrushDocument( ScDocumentUniquePtr pNew, bool bLock )
{
    pDrawBrushSet.reset();
    pBrushDocument = std::move(pNew);
diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx
index ff3dcad..ed2d3c5 100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx
@@ -39,7 +39,7 @@ SelectionObserver::Context::Context (SlideSorter const & rSlideSorter)
        mpSelectionObserver->StartObservation();
}

SelectionObserver::Context::~Context()
SelectionObserver::Context::~Context() COVERITY_NOEXCEPT_FALSE
{
    if (mpSelectionObserver)
        mpSelectionObserver->EndObservation();
diff --git a/slideshow/source/engine/slide/slideanimations.cxx b/slideshow/source/engine/slide/slideanimations.cxx
index 43ac2f8..8c6be3e 100644
--- a/slideshow/source/engine/slide/slideanimations.cxx
+++ b/slideshow/source/engine/slide/slideanimations.cxx
@@ -43,7 +43,7 @@ namespace slideshow
                              "SlideAnimations::SlideAnimations(): Invalid SlideShowContext" );
        }

        SlideAnimations::~SlideAnimations()
        SlideAnimations::~SlideAnimations() COVERITY_NOEXCEPT_FALSE
        {
            if( mpRootNode )
            {
diff --git a/slideshow/source/engine/slide/slideanimations.hxx b/slideshow/source/engine/slide/slideanimations.hxx
index e473902..3954aa3 100644
--- a/slideshow/source/engine/slide/slideanimations.hxx
+++ b/slideshow/source/engine/slide/slideanimations.hxx
@@ -57,7 +57,7 @@ namespace slideshow
             */
            SlideAnimations( const SlideShowContext&     rContext,
                             const ::basegfx::B2DVector& rSlideSize );
            ~SlideAnimations();
            ~SlideAnimations() COVERITY_NOEXCEPT_FALSE;

            /** Import animations from a SMIL root animation node.