Commit afeacd2
committed
Fix assertion failure at end of PITR.
InitXLogInsert() cannot be called in a critical section, because it
allocates memory. But CreateCheckPoint() did that, when called for the
end-of-recovery checkpoint by the startup process.
In the passing, fix the scratch space allocation in InitXLogInsert to go to
the right memory context. Also update the comment at InitXLOGAccess, which
hasn't been totally accurate since hot standby was introduced (in a hot
standby backend, InitXLOGAccess isn't called at backend startup).
Reported by Michael Paquier1 parent a5eb85e commit afeacd2
2 files changed
+15
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7254 | 7254 | | |
7255 | 7255 | | |
7256 | 7256 | | |
7257 | | - | |
7258 | | - | |
7259 | | - | |
7260 | | - | |
| 7257 | + | |
| 7258 | + | |
| 7259 | + | |
7261 | 7260 | | |
7262 | 7261 | | |
7263 | 7262 | | |
| |||
7594 | 7593 | | |
7595 | 7594 | | |
7596 | 7595 | | |
| 7596 | + | |
| 7597 | + | |
| 7598 | + | |
| 7599 | + | |
| 7600 | + | |
| 7601 | + | |
| 7602 | + | |
| 7603 | + | |
| 7604 | + | |
| 7605 | + | |
7597 | 7606 | | |
7598 | 7607 | | |
7599 | 7608 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
891 | 891 | | |
892 | 892 | | |
893 | 893 | | |
894 | | - | |
| 894 | + | |
| 895 | + | |
895 | 896 | | |
0 commit comments