summaryrefslogtreecommitdiff
path: root/cppu/source
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-11-18 12:15:02 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-11-18 12:17:18 +0100
commit6d2e4740a5fbfe8cbf1157a439b73e1bf177c071 (patch)
tree4006a4291c69c8bc78c4a083336daa1c067a1e8a /cppu/source
parent11b0ce9bab436eec81534e9a82bfe76e69b0cf41 (diff)
Assert that typelib_typedescription_release will not destroy pTDR->pType
...which is dereferenced a few lines further down; this is in preparation for a commit addressing cid#440589. Change-Id: I3428216258d928473f85ecd4d025c352c8c83ea0
Diffstat (limited to 'cppu/source')
-rw-r--r--cppu/source/typelib/typelib.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/cppu/source/typelib/typelib.cxx b/cppu/source/typelib/typelib.cxx
index 7f3e808ebda4..392f012a3cce 100644
--- a/cppu/source/typelib/typelib.cxx
+++ b/cppu/source/typelib/typelib.cxx
@@ -1556,6 +1556,7 @@ extern "C" CPPU_DLLPUBLIC void SAL_CALL typelib_typedescription_register(
else if( !pTDR->pType->bOnDemand && (*ppNewDescription)->bOnDemand )
{
// switch from !OnDemand to OnDemand, so the description must be relesed
+ assert(pTDR->pType->nRefCount > 1);
typelib_typedescription_release( pTDR->pType );
}