]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix a segfault when m_current_buffer is NULL
authorGiuseppe Scrivano <gscrivano@gnu.org>
Tue, 15 Sep 2009 22:21:10 +0000 (00:21 +0200)
committerGiuseppe Scrivano <gscrivano@gnu.org>
Tue, 15 Sep 2009 22:21:10 +0000 (00:21 +0200)
src/thread.c

index 972beb2c46240e46cce094131af49f04d665c053..506e9d60afae06b40b839d5648edae96dd134f5c 100644 (file)
@@ -55,8 +55,11 @@ mark_one_thread (struct thread_state *thread)
 
   mark_backtrace (thread->m_backtrace_list);
 
-  XSETBUFFER (tem, thread->m_current_buffer);
-  mark_object (tem);
+  if (thread->m_current_buffer)
+    {
+      XSETBUFFER (tem, thread->m_current_buffer);
+      mark_object (tem);
+    }
 }
 
 static void