*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/postmaster/bgwriter.c,v 1.63 2009/07/31 20:26:22 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/postmaster/bgwriter.c,v 1.64 2009/12/16 22:55:33 petere Exp $
*
*-------------------------------------------------------------------------
*/
pqsignal(SIGWINCH, SIG_DFL);
/* We allow SIGQUIT (quickdie) at all times */
-#ifdef HAVE_SIGPROCMASK
sigdelset(&BlockSig, SIGQUIT);
-#else
- BlockSig &= ~(sigmask(SIGQUIT));
-#endif
/*
* Initialize so that first time-driven event happens at the correct time.
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/postmaster/walwriter.c,v 1.8 2009/07/31 20:26:23 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/postmaster/walwriter.c,v 1.9 2009/12/16 22:55:33 petere Exp $
*
*-------------------------------------------------------------------------
*/
pqsignal(SIGWINCH, SIG_DFL);
/* We allow SIGQUIT (quickdie) at all times */
-#ifdef HAVE_SIGPROCMASK
sigdelset(&BlockSig, SIGQUIT);
-#else
- BlockSig &= ~(sigmask(SIGQUIT));
-#endif
/*
* Create a resource owner to keep track of our resources (not clear that
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.576 2009/12/15 04:57:47 rhaas Exp $
+ * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.577 2009/12/16 22:55:33 petere Exp $
*
* NOTES
* this is the "main" module of the postgres backend and
if (IsUnderPostmaster)
{
/* We allow SIGQUIT (quickdie) at all times */
-#ifdef HAVE_SIGPROCMASK
sigdelset(&BlockSig, SIGQUIT);
-#else
- BlockSig &= ~(sigmask(SIGQUIT));
-#endif
}
PG_SETMASK(&BlockSig); /* block everything except SIGQUIT */
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/libpq/pqsignal.h,v 1.34 2009/08/29 19:26:51 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/libpq/pqsignal.h,v 1.35 2009/12/16 22:55:34 petere Exp $
*
* NOTES
* This shouldn't be in libpq, but the monitor and some other
StartupBlockSig;
#define PG_SETMASK(mask) sigprocmask(SIG_SETMASK, mask, NULL)
-#else
+#else /* not HAVE_SIGPROCMASK */
extern int UnBlockSig,
BlockSig,
StartupBlockSig;
#define PG_SETMASK(mask) pqsigsetmask(*((int*)(mask)))
int pqsigsetmask(int mask);
#endif
-#endif
+
+#define sigdelset(set, signum) (*(set) &= ~(sigmask(signum)))
+#endif /* not HAVE_SIGPROCMASK */
typedef void (*pqsigfunc) (int);