summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2013-10-31 21:25:00 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2013-10-31 21:25:00 (GMT)
commitf46c814d2d9a8f709c8adeb6fdf1da896d80dbee (patch)
treeea5850d6b2e28461641aebb3c82617716170d3b3 /generic
parent4f970286ec90b02eaf3ad950648ca61a79c193e9 (diff)
downloadtk-f46c814d2d9a8f709c8adeb6fdf1da896d80dbee.zip
tk-f46c814d2d9a8f709c8adeb6fdf1da896d80dbee.tar.gz
tk-f46c814d2d9a8f709c8adeb6fdf1da896d80dbee.tar.bz2
Fix refcount bug in FreeFontObjProc. Could result in freeing a TkFont which was already freed.
Diffstat (limited to 'generic')
-rw-r--r--generic/tkFont.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tkFont.c b/generic/tkFont.c
index 1a6474f..9eaaf94 100644
--- a/generic/tkFont.c
+++ b/generic/tkFont.c
@@ -1522,8 +1522,8 @@ FreeFontObjProc(
fontPtr->objRefCount--;
if ((fontPtr->resourceRefCount == 0) && (fontPtr->objRefCount == 0)) {
ckfree((char *) fontPtr);
- objPtr->internalRep.twoPtrValue.ptr1 = NULL;
}
+ objPtr->internalRep.twoPtrValue.ptr1 = NULL;
}
}