Skip to content

Commit d73e041

Browse files
committed
Improve documentation of signal usage for HAVE_SIGPROCMASK and
non-HAVE_SIGPROCMASK cases in pqinitmask().
1 parent ad4f06a commit d73e041

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

src/backend/libpq/pqsignal.c

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*
1010
*
1111
* IDENTIFICATION
12-
* $PostgreSQL: pgsql/src/backend/libpq/pqsignal.c,v 1.39 2005/02/14 23:02:03 momjian Exp $
12+
* $PostgreSQL: pgsql/src/backend/libpq/pqsignal.c,v 1.40 2005/02/14 23:02:35 momjian Exp $
1313
*
1414
* NOTES
1515
* This shouldn't be in libpq, but the monitor and some other
@@ -119,20 +119,24 @@ pqinitmask(void)
119119
sigdelset(&BlockSig, SIGCONT);
120120
sigdelset(&AuthBlockSig, SIGCONT);
121121
#endif
122-
#ifdef SIGTERM
123-
sigdelset(&AuthBlockSig, SIGTERM);
124-
#endif
122+
123+
/* Signals unique to Auth */
125124
#ifdef SIGQUIT
126125
sigdelset(&AuthBlockSig, SIGQUIT);
127126
#endif
127+
#ifdef SIGTERM
128+
sigdelset(&AuthBlockSig, SIGTERM);
129+
#endif
128130
#ifdef SIGALRM
129131
sigdelset(&AuthBlockSig, SIGALRM);
130132
#endif
131133
#else
132134
/* Set the signals we want. */
133135
UnBlockSig = 0;
134-
BlockSig = sigmask(SIGHUP) | sigmask(SIGQUIT) |
136+
BlockSig = sigmask(SIGQUIT) |
135137
sigmask(SIGTERM) | sigmask(SIGALRM) |
138+
/* common signals between two */
139+
sigmask(SIGHUP) |
136140
sigmask(SIGINT) | sigmask(SIGUSR1) |
137141
sigmask(SIGUSR2) | sigmask(SIGCHLD) |
138142
sigmask(SIGWINCH) | sigmask(SIGFPE);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy