mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-09 05:24:44 +01:00
fix assert that wasn't asserting anything
This commit is contained in:
parent
9a46d0713a
commit
6a36c1252d
1 changed files with 1 additions and 6 deletions
|
@ -126,19 +126,14 @@ map_init( MPFORMAL EnvThreadInfo* ti, JNIEnv* env )
|
||||||
static void
|
static void
|
||||||
map_remove( EnvThreadInfo* ti, JNIEnv* env )
|
map_remove( EnvThreadInfo* ti, JNIEnv* env )
|
||||||
{
|
{
|
||||||
#ifdef DEBUG
|
|
||||||
pthread_t self = pthread_self();
|
|
||||||
#endif
|
|
||||||
XP_Bool found = false;
|
XP_Bool found = false;
|
||||||
|
|
||||||
pthread_mutex_lock( &ti->mtxThreads );
|
pthread_mutex_lock( &ti->mtxThreads );
|
||||||
for ( int ii = 0; !found && ii < ti->nEntries; ++ii ) {
|
for ( int ii = 0; !found && ii < ti->nEntries; ++ii ) {
|
||||||
found = env == ti->entries[ii].env;
|
found = env == ti->entries[ii].env;
|
||||||
if ( found ) {
|
if ( found ) {
|
||||||
/* XP_LOGF( "%s: clearing out %dth entry (thread %x)", __func__, ii, */
|
XP_ASSERT( pthread_self() == ti->entries[ii].owner );
|
||||||
/* (int)self ); */
|
|
||||||
ti->entries[ii].env = NULL;
|
ti->entries[ii].env = NULL;
|
||||||
XP_ASSERT( ti->entries[ii].owner = self );
|
|
||||||
ti->entries[ii].owner = 0;
|
ti->entries[ii].owner = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue