summaryrefslogtreecommitdiff
path: root/lib/rpmdb.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rpmdb.c')
-rw-r--r--lib/rpmdb.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/lib/rpmdb.c b/lib/rpmdb.c
index a98b37ad4..cb6ea8f40 100644
--- a/lib/rpmdb.c
+++ b/lib/rpmdb.c
@@ -610,11 +610,11 @@ int rpmdbCheckTerminate(int terminate)
(void) sigfillset(&newMask); /* block all signals */
(void) sigprocmask(SIG_BLOCK, &newMask, &oldMask);
- if (sigismember(&rpmsqCaught, SIGINT)
- || sigismember(&rpmsqCaught, SIGQUIT)
- || sigismember(&rpmsqCaught, SIGHUP)
- || sigismember(&rpmsqCaught, SIGTERM)
- || sigismember(&rpmsqCaught, SIGPIPE)
+ if (rpmsqIsCaught(SIGINT) > 0
+ || rpmsqIsCaught(SIGQUIT) > 0
+ || rpmsqIsCaught(SIGHUP) > 0
+ || rpmsqIsCaught(SIGTERM) > 0
+ || rpmsqIsCaught(SIGPIPE) > 0
|| terminate)
terminating = 1;
@@ -641,9 +641,7 @@ int rpmdbCheckTerminate(int terminate)
int rpmdbCheckSignals(void)
{
if (rpmdbCheckTerminate(0)) {
- /* sigset_t is abstract type */
- rpmlog(RPMLOG_DEBUG, "Exiting on signal(0x%lx) ...\n",
- *((unsigned long *)&rpmsqCaught));
+ rpmlog(RPMLOG_DEBUG, "Exiting on signal...\n");
exit(EXIT_FAILURE);
}
return 0;