diff options
Diffstat (limited to 'src/backend/tcop/postgres.c')
-rw-r--r-- | src/backend/tcop/postgres.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c index 89d2d4a7b8a..9abc11bea51 100644 --- a/src/backend/tcop/postgres.c +++ b/src/backend/tcop/postgres.c @@ -2806,6 +2806,16 @@ RecoveryConflictInterrupt(ProcSignalReason reason) } } + /* + * Set the process latch. This function essentially emulates signal + * handlers like die() and StatementCancelHandler() and it seems prudent + * to behave similarly as they do. Alternatively all plain backend code + * waiting on that latch, expecting to get interrupted by query cancels et + * al., would also need to set set_latch_on_sigusr1. + */ + if (MyProc) + SetLatch(&MyProc->procLatch); + errno = save_errno; } |