summaryrefslogtreecommitdiffstats
path: root/include/vcl/outdev.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-03-23 10:25:26 +0200
committerMichael Meeks <michael.meeks@collabora.com>2015-04-10 13:07:04 +0100
commita6e5ac3be1398aa63fab1d751d6238daeb3a2b2f (patch)
tree416ada012c62f6f28f5836bfc65f35333daa5574 /include/vcl/outdev.hxx
parentcalling delete on VclPtr (diff)
downloadcore-a6e5ac3be1398aa63fab1d751d6238daeb3a2b2f.tar.gz
core-a6e5ac3be1398aa63fab1d751d6238daeb3a2b2f.zip
vclwidget: add some safety net asserts
Change-Id: I5fa19ec6161ab97eb7df8b52a268917f41ae2205
Diffstat (limited to 'include/vcl/outdev.hxx')
-rw-r--r--include/vcl/outdev.hxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index f5875b7ccea1..4e2341af6711 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -274,11 +274,13 @@ private:
inline void acquire() const
{
+ assert(!mbDisposed);
mnRefCnt++;
}
inline void release() const
{
+ assert(mnRefCnt>0);
if (!--mnRefCnt)
delete const_cast<OutputDevice*>(this);
}