diff options
author | Andres Freund | 2015-02-03 22:25:47 +0000 |
---|---|---|
committer | Andres Freund | 2015-02-03 22:25:47 +0000 |
commit | 2505ce0be0b686c5a0a5141e9d080e7fdc35988a (patch) | |
tree | 32291d2aaca4045b4e1949fd2e6b5d8d70e46c55 /src/backend/tcop/postgres.c | |
parent | d06995710bc7e347d39866c1793ae282498d65e0 (diff) |
Remove remnants of ImmediateInterruptOK handling.
Now that nothing sets ImmediateInterruptOK to true anymore, we can
remove all the supporting code.
Reviewed-By: Heikki Linnakangas
Diffstat (limited to 'src/backend/tcop/postgres.c')
-rw-r--r-- | src/backend/tcop/postgres.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c index 63573046a9e..f2a426d792a 100644 --- a/src/backend/tcop/postgres.c +++ b/src/backend/tcop/postgres.c @@ -2648,13 +2648,6 @@ die(SIGNAL_ARGS) { InterruptPending = true; ProcDiePending = true; - - /* - * If we're waiting for input or a lock so that it's safe to - * interrupt, service the interrupt immediately - */ - if (ImmediateInterruptOK) - ProcessInterrupts(); } /* If we're still here, waken anything waiting on the process latch */ @@ -2688,13 +2681,6 @@ StatementCancelHandler(SIGNAL_ARGS) { InterruptPending = true; QueryCancelPending = true; - - /* - * If we're waiting for input or a lock so that it's safe to - * interrupt, service the interrupt immediately - */ - if (ImmediateInterruptOK) - ProcessInterrupts(); } /* If we're still here, waken anything waiting on the process latch */ @@ -2835,13 +2821,6 @@ RecoveryConflictInterrupt(ProcSignalReason reason) */ if (reason == PROCSIG_RECOVERY_CONFLICT_DATABASE) RecoveryConflictRetryable = false; - - /* - * If we're waiting for input or a lock so that it's safe to - * interrupt, service the interrupt immediately. - */ - if (ImmediateInterruptOK) - ProcessInterrupts(); } /* @@ -2875,7 +2854,6 @@ ProcessInterrupts(void) { ProcDiePending = false; QueryCancelPending = false; /* ProcDie trumps QueryCancel */ - ImmediateInterruptOK = false; /* not idle anymore */ LockErrorCleanup(); /* As in quickdie, don't risk sending to client during auth */ if (ClientAuthInProgress && whereToSendOutput == DestRemote) @@ -2914,7 +2892,6 @@ ProcessInterrupts(void) if (ClientConnectionLost) { QueryCancelPending = false; /* lost connection trumps QueryCancel */ - ImmediateInterruptOK = false; /* not idle anymore */ LockErrorCleanup(); /* don't send to client, we already know the connection to be dead. */ whereToSendOutput = DestNone; @@ -2932,7 +2909,6 @@ ProcessInterrupts(void) if (RecoveryConflictPending && DoingCommandRead) { QueryCancelPending = false; /* this trumps QueryCancel */ - ImmediateInterruptOK = false; /* not idle anymore */ RecoveryConflictPending = false; LockErrorCleanup(); pgstat_report_recovery_conflict(RecoveryConflictReason); @@ -2970,7 +2946,6 @@ ProcessInterrupts(void) */ if (get_timeout_indicator(LOCK_TIMEOUT, true)) { - ImmediateInterruptOK = false; /* not idle anymore */ (void) get_timeout_indicator(STATEMENT_TIMEOUT, true); LockErrorCleanup(); ereport(ERROR, @@ -2979,7 +2954,6 @@ ProcessInterrupts(void) } if (get_timeout_indicator(STATEMENT_TIMEOUT, true)) { - ImmediateInterruptOK = false; /* not idle anymore */ LockErrorCleanup(); ereport(ERROR, (errcode(ERRCODE_QUERY_CANCELED), @@ -2987,7 +2961,6 @@ ProcessInterrupts(void) } if (IsAutoVacuumWorkerProcess()) { - ImmediateInterruptOK = false; /* not idle anymore */ LockErrorCleanup(); ereport(ERROR, (errcode(ERRCODE_QUERY_CANCELED), @@ -2995,7 +2968,6 @@ ProcessInterrupts(void) } if (RecoveryConflictPending) { - ImmediateInterruptOK = false; /* not idle anymore */ RecoveryConflictPending = false; LockErrorCleanup(); pgstat_report_recovery_conflict(RecoveryConflictReason); @@ -3012,7 +2984,6 @@ ProcessInterrupts(void) */ if (!DoingCommandRead) { - ImmediateInterruptOK = false; /* not idle anymore */ LockErrorCleanup(); ereport(ERROR, (errcode(ERRCODE_QUERY_CANCELED), |