Repository navigation
Commit 3efdda8
cli: Kill child replay processes when parent dies on Linux
When Fossilize is forcefully terminated or crashes,
the child replay processes currently become orphans and continue to compile shaders in the background,
leading to excessive CPU/RAM usage in some cases where the existing
reaping logic fails.
This adds PR_SET_PDEATHSIG to guarantee child processes are terminated immediately when the parent process dies,
matching the expected lifecycle of the application.
PR squashed and stipped down by HansKristian-Work.1 parent 137407b commit 3efdda8
2 files changed
Lines changed: 26 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
35 | 36 | | |
36 | 37 | | |
37 | 38 | | |
| |||
524 | 525 | | |
525 | 526 | | |
526 | 527 | | |
| 528 | + | |
527 | 529 | | |
528 | 530 | | |
529 | 531 | | |
| |||
560 | 562 | | |
561 | 563 | | |
562 | 564 | | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
563 | 576 | | |
564 | 577 | | |
565 | 578 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
948 | 949 | | |
949 | 950 | | |
950 | 951 | | |
| 952 | + | |
951 | 953 | | |
952 | 954 | | |
953 | 955 | | |
| |||
966 | 968 | | |
967 | 969 | | |
968 | 970 | | |
| 971 | + | |
| 972 | + | |
| 973 | + | |
| 974 | + | |
| 975 | + | |
| 976 | + | |
| 977 | + | |
| 978 | + | |
| 979 | + | |
| 980 | + | |
| 981 | + | |
969 | 982 | | |
970 | 983 | | |
971 | 984 | | |
| |||
0 commit comments