]> git.eshelyaron.com Git - emacs.git/commitdiff
(BLOCK_INPUT_ALLOC, UNBLOCK_INPUT_ALLOC): Undo previous
authorYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Sun, 27 Aug 2006 07:08:31 +0000 (07:08 +0000)
committerYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Sun, 27 Aug 2006 07:08:31 +0000 (07:08 +0000)
change.  Move mutex lock/unlock operations inside BLOCK_INPUT.

src/alloc.c

index 192b974196ff3692d8dd5843298c9cb69819a190..2fd50009649a5af131fe3f7f5531a02d02271b8e 100644 (file)
@@ -130,27 +130,17 @@ static pthread_mutex_t alloc_mutex;
 #define BLOCK_INPUT_ALLOC                       \
   do                                            \
     {                                           \
-      if (!in_sighandler)                       \
-        {                                       \
-           pthread_mutex_lock (&alloc_mutex);   \
-           if (pthread_self () == main_thread)  \
-             BLOCK_INPUT;                       \
-           else                                 \
-             sigblock (sigmask (SIGIO));        \
-        }                                       \
+      if (pthread_self () == main_thread)      \
+       BLOCK_INPUT;                            \
+      pthread_mutex_lock (&alloc_mutex);       \
     }                                           \
   while (0)
 #define UNBLOCK_INPUT_ALLOC                     \
   do                                            \
     {                                           \
-      if (!in_sighandler)                       \
-        {                                       \
-           pthread_mutex_unlock (&alloc_mutex); \
-           if (pthread_self () == main_thread)  \
-             UNBLOCK_INPUT;                     \
-           else                                 \
-             sigunblock (sigmask (SIGIO));      \
-        }                                       \
+      pthread_mutex_unlock (&alloc_mutex);     \
+      if (pthread_self () == main_thread)      \
+       UNBLOCK_INPUT;                          \
     }                                           \
   while (0)