Commit e497f1c2 authored by sasha@mysql.sashanet.com's avatar sasha@mysql.sashanet.com

Merge work:/home/bk/mysql-4.0

into mysql.sashanet.com:/reiser-data/mysql-4.0
parents 8ff6508f 28848fa9
......@@ -725,6 +725,12 @@ byte *my_compress_alloc(const byte *packet, ulong *len, ulong *complen);
ulong checksum(const byte *mem, uint count);
uint my_bit_log2(ulong value);
#if defined(SAFE_MUTEX) && !defined(DBUG_OFF)
#define DBUG_ASSERT_LOCK(lock) DBUG_ASSERT((lock)->count == 1 && \
(lock)->thread == pthread_self())
#else
#define DBUG_ASSERT_LOCK(lock)
#endif
#if defined(_MSC_VER) && !defined(__WIN__)
extern void sleep(int sec);
......
......@@ -361,7 +361,7 @@ int terminate_slave_thread(THD* thd, pthread_mutex_t* term_lock,
abstime.tv_sec=tv.tv_sec+2;
abstime.tv_nsec=tv.tv_usec*1000;
#endif
DBUG_ASSERT(cond_lock->count > 0 && cond_lock->thread == pthread_self());
DBUG_ASSERT_LOCK(cond_lock);
pthread_cond_timedwait(term_cond, cond_lock, &abstime);
if (*slave_running)
KICK_SLAVE(thd);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment