forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitfb489e4
committed
In bootstrap mode, use default signal handling for SIGINT etc.
Previously, the code pointed the standard process-termination signalsto postgres.c's die(). That would typically result in an attempt toexecute a transaction abort, which is not possible in bootstrap mode,leading to PANIC. This choice seems to be a leftover from an old codestructure in which the same signal-assignment code was used for manysorts of auxiliary processes, including interactive standalonebackends. It's not very sensible for bootstrap mode, which has nointerest in either interactivity or continuing after an error. We canget better behavior with less effort by just letting normal processtermination happen, after which the parent initdb process will clean up.This is basically cosmetic in any case, since initdb will react thesame way whether bootstrap dies on a signal or abort(). Given thelack of previous complaints, I don't feel a need to back-patch,even though the behavior is old.Discussion:https://postgr.es/m/3850b11a.5121.16aaf827e4a.Coremail.thunder1@126.com1 parent037165c commitfb489e4
1 file changed
+9
-5
lines changedLines changed: 9 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
558 | 558 |
| |
559 | 559 |
| |
560 | 560 |
| |
561 |
| - | |
562 |
| - | |
563 |
| - | |
564 |
| - | |
565 |
| - | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
566 | 570 |
| |
567 | 571 |
| |
568 | 572 |
| |
|
0 commit comments
Comments
(0)