From 9fc0cb74b716654c63cc8e47e81248029dedfefa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Czerpak?= Date: Sat, 4 Jan 2014 18:22:04 +0100 Subject: [PATCH] 2014-01-04 18:22 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) * src/vm/hvm.c ! release TSD handle in thread static destructors. It should fix problem reported by Lorenzo. --- ChangeLog.txt | 5 +++++ src/vm/hvm.c | 4 +--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 009fefeccf..c5dd7974ad 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -10,6 +10,11 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2014-01-04 18:22 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) + * src/vm/hvm.c + ! release TSD handle in thread static destructors. + It should fix problem reported by Lorenzo. + 2014-01-03 12:39 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) * contrib/gtqtc/gtqtc.hbc * contrib/gtqtc/gtqtc.hbp diff --git a/src/vm/hvm.c b/src/vm/hvm.c index 84391f9bd1..f275338f28 100644 --- a/src/vm/hvm.c +++ b/src/vm/hvm.c @@ -6482,9 +6482,7 @@ static void hb_vmTSVRefClear( void * value ) if( HB_IS_COMPLEX( &( ( PHB_TSVREF ) value )->source ) ) hb_itemClear( &( ( PHB_TSVREF ) value )->source ); - pItem = ( PHB_ITEM ) hb_stackTestTSD( &( ( PHB_TSVREF ) value )->threadData ); - if( pItem && HB_IS_COMPLEX( pItem ) ) - hb_itemClear( pItem ); + hb_stackReleaseTSD( &( ( PHB_TSVREF ) value )->threadData ); hb_xfree( value ); }