forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitbed5eac
committed
Unset MyBEEntry, making elog.c's call to pgstat_get_my_query_id() safe.
Previously log messages late during shutdown could end up using either anotherbackend's PgBackendStatus (multi user) or segfault (single user) becausepgstat_get_my_query_id()'s check for !MyBEEntry didn't filter out use afterpgstat_beshutdown_hook().This became a bug in4f0b096, but was a bit fishy before. But giventhere's no known problematic cases before 14, it doesn't seem worthbackpatching further.Also fixes a wrong filename in a comment, introduced ine102504.Reported-By: Andres Freund <andres@anarazel.de>Reviewed-By: Julien Rouhaud <rjuju123@gmail.com>Discussion:https://postgr.es/m/Julien Rouhaud <rjuju123@gmail.com>Backpatch: 14-1 parent4cd7a18 commitbed5eac
1 file changed
+4
-1
lines changedLines changed: 4 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
46 | 46 |
| |
47 | 47 |
| |
48 | 48 |
| |
49 |
| - | |
| 49 | + | |
50 | 50 |
| |
51 | 51 |
| |
52 | 52 |
| |
| |||
469 | 469 |
| |
470 | 470 |
| |
471 | 471 |
| |
| 472 | + | |
| 473 | + | |
| 474 | + | |
472 | 475 |
| |
473 | 476 |
| |
474 | 477 |
| |
|
0 commit comments
Comments
(0)