aboutsummaryrefslogtreecommitdiff
path: root/src/backend/jit/llvm/llvmjit_error.cpp
diff options
context:
space:
mode:
authorThomas Munro <tmunro@postgresql.org>2021-02-15 13:32:58 +1300
committerThomas Munro <tmunro@postgresql.org>2021-02-15 14:27:33 +1300
commit637668fb1d17ad789e392a40ff09694ff1aabffb (patch)
tree0253d1c9dfda8289599141c58acc3fef865bd09d /src/backend/jit/llvm/llvmjit_error.cpp
parentb83dcf792869fb4a9270d17c961eab75f51c44e4 (diff)
downloadpostgresql-637668fb1d17ad789e392a40ff09694ff1aabffb.tar.gz
postgresql-637668fb1d17ad789e392a40ff09694ff1aabffb.zip
Hold interrupts while running dsm_detach() callbacks.
While cleaning up after a parallel query or parallel index creation that created temporary files, we could be interrupted by a statement timeout. The error handling path would then fail to clean up the files when it ran dsm_detach() again, because the callback was already popped off the list. Prevent this hazard by holding interrupts while the cleanup code runs. Thanks to Heikki Linnakangas for this suggestion, and also to Kyotaro Horiguchi, Masahiko Sawada, Justin Pryzby and Tom Lane for discussion of this and earlier ideas on how to fix the problem. Back-patch to all supported releases. Reported-by: Justin Pryzby <pryzby@telsasoft.com> Discussion: https://postgr.es/m/20191212180506.GR2082@telsasoft.com
Diffstat (limited to 'src/backend/jit/llvm/llvmjit_error.cpp')
0 files changed, 0 insertions, 0 deletions