]> git.eshelyaron.com Git - emacs.git/commitdiff
Remove desired_buffer from the thread_state struct.
authorGiuseppe Scrivano <gscrivano@gnu.org>
Wed, 11 Nov 2009 09:55:48 +0000 (10:55 +0100)
committerGiuseppe Scrivano <gscrivano@gnu.org>
Wed, 11 Nov 2009 09:55:48 +0000 (10:55 +0100)
src/thread.c
src/thread.h

index ca8317822ab84acec73b9866df1af0e5da1e6c3b..b142c8e679f466c442d1fcc820da01b8a10c0b25 100644 (file)
@@ -229,8 +229,7 @@ run_thread (void *state)
      typically wait for the parent thread to release it first.  */
   XSETBUFFER (buffer, self->m_current_buffer);
   GCPRO1 (buffer);
-  self->desired_buffer = (struct buffer *) buffer;
-  self->m_current_buffer = 0;
+  self->m_current_buffer = (struct buffer *) buffer;
 
   pthread_mutex_lock (&global_lock);
 
@@ -402,16 +401,6 @@ thread_notify_kill_buffer (register struct buffer *b)
   struct thread_state *it = all_threads;
   for (; it; it = it->next_thread)
     {
-      if (b == it->desired_buffer)
-        {
-          register Lisp_Object buf;
-          XSETBUFFER (buf, it->desired_buffer);
-          tem = Fother_buffer (buf, Qnil, Qnil);
-          it->desired_buffer = XBUFFER (tem);
-          if (b == it->desired_buffer)
-            return Qnil;
-        }
-
       if (b == it->m_current_buffer)
         {
           register Lisp_Object buf;
index df98276fc81aa07a1611c450773aa0873170db2f..e58d2bebfdef7d12917da88d6c470cffc49caa0a 100644 (file)
@@ -111,10 +111,6 @@ struct thread_state
 
   pthread_t pthread_id;
 
-  /* Used internally by the scheduler, the buffer that the thread wants a lock
-     for.  */
-  struct buffer *desired_buffer;
-
   /* If nonzero the thread is blocked on a wait so it is not schedulable.  */
   int blocked;
 };