index 89d2d4a7b8a0ae14f37ac7b91ebe22a9e889110b..9abc11bea51ffc7295a093f274cd2e0aa9cc0154 100644 (file)
}
}
+ /*
+ * 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;
}