pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Use 64 bit type for BufFileSize(). 2+ messages / 1 participants [nested] [flat]
* pgsql: Use 64 bit type for BufFileSize(). @ 2018-11-15 01:06 Thomas Munro <tmunro@postgresql.org> 0 siblings, 0 replies; 2+ messages in thread From: Thomas Munro @ 2018-11-15 01:06 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Use 64 bit type for BufFileSize(). BufFileSize() can't use off_t, because it's only 32 bits wide on some systems. BufFile objects can have many 1GB segments so the total size can exceed 2^31. The only known client of the function is parallel CREATE INDEX, which was reported to fail when building large indexes on Windows. Though this is technically an ABI break on platforms with a 32 bit off_t and we might normally avoid back-patching it, the function is brand new and thus unlikely to have been discovered by extension authors yet, and it's fairly thoroughly broken on those platforms anyway, so just fix it. Defect in 9da0cc35. Bug #15460. Back-patch to 11, where this function landed. Author: Thomas Munro Reported-by: Paul van der Linden, Pavel Oskin Reviewed-by: Peter Geoghegan Discussion: https://postgr.es/m/15460-b6db80de822fa0ad%40postgresql.org Discussion: https://postgr.es/m/CAHDGBJP_GsESbTt4P3FZA8kMUKuYxjg57XHF7NRBoKnR%3DCAR-g%40mail.gmail.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/aa5518304213a762b62ebe3dbb057d220d8976eb Modified Files -------------- src/backend/storage/file/buffile.c | 6 +++--- src/backend/utils/sort/logtape.c | 2 +- src/include/storage/buffile.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Use 64 bit type for BufFileSize(). @ 2018-11-15 01:06 Thomas Munro <tmunro@postgresql.org> 0 siblings, 0 replies; 2+ messages in thread From: Thomas Munro @ 2018-11-15 01:06 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Use 64 bit type for BufFileSize(). BufFileSize() can't use off_t, because it's only 32 bits wide on some systems. BufFile objects can have many 1GB segments so the total size can exceed 2^31. The only known client of the function is parallel CREATE INDEX, which was reported to fail when building large indexes on Windows. Though this is technically an ABI break on platforms with a 32 bit off_t and we might normally avoid back-patching it, the function is brand new and thus unlikely to have been discovered by extension authors yet, and it's fairly thoroughly broken on those platforms anyway, so just fix it. Defect in 9da0cc35. Bug #15460. Back-patch to 11, where this function landed. Author: Thomas Munro Reported-by: Paul van der Linden, Pavel Oskin Reviewed-by: Peter Geoghegan Discussion: https://postgr.es/m/15460-b6db80de822fa0ad%40postgresql.org Discussion: https://postgr.es/m/CAHDGBJP_GsESbTt4P3FZA8kMUKuYxjg57XHF7NRBoKnR%3DCAR-g%40mail.gmail.com Branch ------ REL_11_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/fa2ceaca435889119f8a40ae7b000cd5229a0dd0 Modified Files -------------- src/backend/storage/file/buffile.c | 6 +++--- src/backend/utils/sort/logtape.c | 2 +- src/include/storage/buffile.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2018-11-15 01:06 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2018-11-15 01:06 pgsql: Use 64 bit type for BufFileSize(). Thomas Munro <tmunro@postgresql.org> 2018-11-15 01:06 pgsql: Use 64 bit type for BufFileSize(). Thomas Munro <tmunro@postgresql.org>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox