pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Fix bug in TOC file error message printing 7+ messages / 1 participants [nested] [flat]
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:17 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:17 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/998d060f3db79c6918cb4a547695be150833f9a4 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:18 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:18 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL_14_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/3e2f32b01d3b6868022c8381b28e8fc5399baeb9 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:19 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:19 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL_13_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/687fe8a9d7a636d0792da39eb4dc1630741c7937 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:20 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:20 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL_12_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/e788883de715be00733615c2224149332f49b0f0 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:20 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:20 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL_11_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/038892c8101845b6b4364cf2f5773207c4a4525c Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:20 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:20 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL_10_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/4fda03b671a6849972d0a66b4af5518cd2a97a70 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix bug in TOC file error message printing @ 2021-10-19 11:20 Daniel Gustafsson <dgustafsson@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Daniel Gustafsson @ 2021-10-19 11:20 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix bug in TOC file error message printing If the blob TOC file cannot be parsed, the error message was failing to print the filename as the variable holding it was shadowed by the destination buffer for parsing. When the filename fails to parse, the error will print an empty string: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "": .. ..instead of the intended error message: ./pg_restore -d foo -F d dump pg_restore: error: invalid line in large object TOC file "dump/blobs.toc": .. Fix by renaming both variables as the shared name was too generic to store either and still convey what the variable held. Backpatch all the way down to 9.6. Reviewed-by: Tom Lane Discussion: https://postgr.es/m/A2B151F5-B32B-4F2C-BA4A-6870856D9BDE@yesql.se Backpatch-through: 9.6 Branch ------ REL9_6_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/ef1f15819a389dcb62daa3c60b7af56fbd5695e2 Modified Files -------------- src/bin/pg_dump/pg_backup_directory.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
end of thread, other threads:[~2021-10-19 11:20 UTC | newest] Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2021-10-19 11:17 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:18 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:19 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:20 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:20 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:20 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@postgresql.org> 2021-10-19 11:20 pgsql: Fix bug in TOC file error message printing Daniel Gustafsson <dgustafsson@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