Commit 5ca4e44
committed
On Darwin, detect and report a multithreaded postmaster.
Darwin --enable-nls builds use a substitute setlocale() that may start a
thread. Buildfarm member orangutan experienced BackendList corruption
on account of different postmaster threads executing signal handlers
simultaneously. Furthermore, a multithreaded postmaster risks undefined
behavior from sigprocmask() and fork(). Emit LOG messages about the
problem and its workaround. Back-patch to 9.0 (all supported versions).1 parent 603eb79 commit 5ca4e44
File tree
5 files changed
+61
-2
lines changed- src
- backend/postmaster
- include
- port
5 files changed
+61
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19302 | 19302 | | |
19303 | 19303 | | |
19304 | 19304 | | |
19305 | | - | |
| 19305 | + | |
| 19306 | + | |
19306 | 19307 | | |
19307 | 19308 | | |
19308 | 19309 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1241 | 1241 | | |
1242 | 1242 | | |
1243 | 1243 | | |
1244 | | - | |
| 1244 | + | |
1245 | 1245 | | |
1246 | 1246 | | |
1247 | 1247 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
94 | 98 | | |
95 | 99 | | |
96 | 100 | | |
| |||
1105 | 1109 | | |
1106 | 1110 | | |
1107 | 1111 | | |
| 1112 | + | |
| 1113 | + | |
| 1114 | + | |
| 1115 | + | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
| 1120 | + | |
| 1121 | + | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
| 1129 | + | |
1108 | 1130 | | |
1109 | 1131 | | |
1110 | 1132 | | |
| |||
1441 | 1463 | | |
1442 | 1464 | | |
1443 | 1465 | | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
1444 | 1475 | | |
1445 | 1476 | | |
1446 | 1477 | | |
| |||
4211 | 4242 | | |
4212 | 4243 | | |
4213 | 4244 | | |
| 4245 | + | |
| 4246 | + | |
| 4247 | + | |
| 4248 | + | |
| 4249 | + | |
| 4250 | + | |
| 4251 | + | |
| 4252 | + | |
| 4253 | + | |
| 4254 | + | |
| 4255 | + | |
| 4256 | + | |
4214 | 4257 | | |
4215 | 4258 | | |
4216 | 4259 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
387 | 387 | | |
388 | 388 | | |
389 | 389 | | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
390 | 393 | | |
391 | 394 | | |
392 | 395 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
571 | 571 | | |
572 | 572 | | |
573 | 573 | | |
| 574 | + | |
574 | 575 | | |
575 | 576 | | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
576 | 588 | | |
577 | 589 | | |
578 | 590 | | |
| |||
0 commit comments