]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Fix temporary tablespaces for shared filesets
authorMagnus Hagander <magnus@hagander.net>
Fri, 3 Jul 2020 13:09:06 +0000 (15:09 +0200)
committerMagnus Hagander <magnus@hagander.net>
Fri, 3 Jul 2020 13:10:33 +0000 (15:10 +0200)
commit28a862e9dcc4559e7c41c8f7d84dc7b3a0c928a2
tree12b87c9731a4e48e7fbe1dc36c7b8b73f8bd23d6
parent6425d6f6aa1af8b2db94ade64107fb268a7f114c
Fix temporary tablespaces for shared filesets

A likely copy/paste error in 98e8b480532 from  back in 2004 would
cause temp tablespace to be reset to InvalidOid if temp_tablespaces
was set to the same value as the primary tablespace in the database.
This would cause shared filesets (such as for parallel hash joins)
to ignore them, putting the temporary files in the default tablespace
instead of the configured one. The bug is in the old code, but it
appears to have been exposed only once we had shared filesets.

Reviewed-By: Daniel Gustafsson
Discussion: https://postgr.es/m/CABUevExg5YEsOvqMxrjoNvb3ApVyH+9jggWGKwTDFyFCVWczGQ@mail.gmail.com
Backpatch-through: 9.5
src/backend/commands/tablespace.c