Commit 86b7194c authored by unknown's avatar unknown

Debug code fixed.

parent d84e2a7d
...@@ -67,6 +67,9 @@ void wqueue_add_to_queue(WQUEUE *wqueue, struct st_my_thread_var *thread) ...@@ -67,6 +67,9 @@ void wqueue_add_to_queue(WQUEUE *wqueue, struct st_my_thread_var *thread)
thread->next= last->next; thread->next= last->next;
last->next= thread; last->next= thread;
} }
#ifndef DBUG_OFF
thread->prev= NULL; /* force segfault if used */
#endif
wqueue->last_thread= thread; wqueue->last_thread= thread;
} }
...@@ -156,9 +159,6 @@ void wqueue_release_one_locktype_from_queue(WQUEUE *wqueue) ...@@ -156,9 +159,6 @@ void wqueue_release_one_locktype_from_queue(WQUEUE *wqueue)
{ {
/* release first waiting for write lock */ /* release first waiting for write lock */
pthread_cond_signal(&next->suspend); pthread_cond_signal(&next->suspend);
#ifndef DBUG_OFF
next->prev= NULL; /* force segfault if used */
#endif
if (next == last) if (next == last)
wqueue->last_thread= NULL; wqueue->last_thread= NULL;
else else
...@@ -170,9 +170,6 @@ void wqueue_release_one_locktype_from_queue(WQUEUE *wqueue) ...@@ -170,9 +170,6 @@ void wqueue_release_one_locktype_from_queue(WQUEUE *wqueue)
{ {
thread= next; thread= next;
next= thread->next; next= thread->next;
#ifndef DBUG_OFF
thread->prev= NULL; /* force segfault if used */
#endif
if (thread->lock_type == MY_PTHREAD_LOCK_WRITE) if (thread->lock_type == MY_PTHREAD_LOCK_WRITE)
{ {
/* skip waiting for write lock */ /* skip waiting for write lock */
......
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