]> granicus.if.org Git - mutt/commitdiff
Now, I should have got the signal handling right.
authorThomas Roessler <roessler@does-not-exist.org>
Wed, 1 Dec 1999 12:06:31 +0000 (12:06 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Wed, 1 Dec 1999 12:06:31 +0000 (12:06 +0000)
imap/util.c

index 10db94606996ec77738600a50cbe143747648b95..81aef5f2adb7691bd3cbe9270931603db7bf223c 100644 (file)
@@ -319,7 +319,7 @@ int imap_wait_keepalive (pid_t pid)
 {
   struct sigaction oldalrm;
   struct sigaction act;
-  sigset_t oldblocked;
+  sigset_t oldmask;
   int rc;
 
   short imap_passive = option (OPTIMAPPASSIVE);
@@ -327,7 +327,7 @@ int imap_wait_keepalive (pid_t pid)
   set_option (OPTIMAPPASSIVE);
   set_option (OPTKEEPQUIET);
 
-  sigprocmask (SIG_BLOCK, NULL, &oldblocked);
+  sigprocmask (SIG_SETMASK, NULL, &oldmask);
 
   sigemptyset (&act.sa_mask);
   act.sa_handler = alrm_handler;
@@ -352,7 +352,7 @@ int imap_wait_keepalive (pid_t pid)
   alarm (0);   /* cancel a possibly pending alarm */
   
   sigaction (SIGALRM, &oldalrm, NULL);
-  sigprocmask (SIG_BLOCK, &oldblocked, NULL);
+  sigprocmask (SIG_SETMASK, &oldmask, NULL);
 
   unset_option (OPTKEEPQUIET);
   if (!imap_passive)