summaryrefslogtreecommitdiff
path: root/include/tools/ref.hxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-02-10 09:24:16 +0000
committerCaolán McNamara <caolanm@redhat.com>2017-06-06 14:15:43 +0200
commitd0069e5189f5410e1db7aa395f0754109e872f46 (patch)
tree30c860e8d780c3461c6048be9594f642f03de5de /include/tools/ref.hxx
parentcc2db25645ede743bdc3824fe7d26ea4beda6a96 (diff)
add COVERITY_NOEXCEPT_FALSE
to markup dtors that coverity warns might throw exceptions which won't throw in practice, or where std::terminate is an acceptable response if they do Change-Id: I32b94814e8245372e1d1dc36be0d81e3564042f4 Reviewed-on: https://gerrit.libreoffice.org/38318 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'include/tools/ref.hxx')
-rw-r--r--include/tools/ref.hxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/tools/ref.hxx b/include/tools/ref.hxx
index bb32d486339e..68a1c3f56f09 100644
--- a/include/tools/ref.hxx
+++ b/include/tools/ref.hxx
@@ -126,7 +126,7 @@ class TOOLS_DLLPUBLIC SvRefBase
unsigned int bNoDelete : 1;
protected:
- virtual ~SvRefBase();
+ virtual ~SvRefBase() COVERITY_NOEXCEPT_FALSE;
public:
SvRefBase() : nRefCount(0), bNoDelete(1) {}
@@ -217,6 +217,9 @@ public:
SvCompatWeakRef( ) {}
SvCompatWeakRef( T* pObj )
{ if( pObj ) _xHdl = pObj->GetHdl(); }
+#if defined(__COVERITY__)
+ ~SvCompatWeakRef() COVERITY_NOEXCEPT_FALSE {}
+#endif
SvCompatWeakRef& operator = ( T * pObj )
{ _xHdl = pObj ? pObj->GetHdl() : nullptr; return *this; }
bool is() const