pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Fix Y2038 issues with MyStartTime. 7+ messages / 1 participants [nested] [flat]
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/5d6187d2a28326b3414c394ec4c28c51bb513c44 Modified Files -------------- contrib/postgres_fdw/option.c | 2 +- src/backend/utils/error/csvlog.c | 2 +- src/backend/utils/error/elog.c | 6 +++--- src/backend/utils/error/jsonlog.c | 4 ++-- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_13_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/b255493aefe9eea0ba2592d485819aaad21193fb Modified Files -------------- src/backend/utils/error/elog.c | 8 ++++---- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_14_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/5cea7168dfe622fe2e474bdfae59f966aad53ce3 Modified Files -------------- src/backend/utils/error/elog.c | 8 ++++---- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_12_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/c91d0af0a2ad3d3176eaf508281a4e29bb1975b8 Modified Files -------------- src/backend/utils/error/elog.c | 8 ++++---- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_17_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/a356d23fd3ad7884895a68d4f9c9fdd643d686ae Modified Files -------------- contrib/postgres_fdw/option.c | 2 +- src/backend/utils/error/csvlog.c | 2 +- src/backend/utils/error/elog.c | 6 +++--- src/backend/utils/error/jsonlog.c | 4 ++-- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_16_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/8aaf88b63de3d6e665b0fcf1ff123f08b961fe66 Modified Files -------------- contrib/postgres_fdw/option.c | 2 +- src/backend/utils/error/csvlog.c | 2 +- src/backend/utils/error/elog.c | 6 +++--- src/backend/utils/error/jsonlog.c | 4 ++-- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
* pgsql: Fix Y2038 issues with MyStartTime. @ 2024-10-07 18:52 Nathan Bossart <nathan@postgresql.org> 0 siblings, 0 replies; 7+ messages in thread From: Nathan Bossart @ 2024-10-07 18:52 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Fix Y2038 issues with MyStartTime. Several places treat MyStartTime as a "long", which is only 32 bits wide on some platforms. In reality, MyStartTime is a pg_time_t, i.e., a signed 64-bit integer. This will lead to interesting bugs on the aforementioned systems in 2038 when signed 32-bit integers are no longer sufficient to store Unix time (e.g., "pg_ctl start" hanging). To fix, ensure that MyStartTime is handled as a 64-bit value everywhere. (Of course, users will need to ensure that time_t is 64 bits wide on their system, too.) Co-authored-by: Max Johnson Discussion: https://postgr.es/m/CO1PR07MB905262E8AC270FAAACED66008D682%40CO1PR07MB9052.namprd07.prod.outlook.com Backpatch-through: 12 Branch ------ REL_15_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/01731eeeaa9665b47a45b7d2c967ef4c06a56d1b Modified Files -------------- contrib/postgres_fdw/option.c | 2 +- src/backend/utils/error/csvlog.c | 2 +- src/backend/utils/error/elog.c | 6 +++--- src/backend/utils/error/jsonlog.c | 4 ++-- src/backend/utils/init/miscinit.c | 4 ++-- src/bin/pg_ctl/pg_ctl.c | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) ^ permalink raw reply [nested|flat] 7+ messages in thread
end of thread, other threads:[~2024-10-07 18:52 UTC | newest] Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@postgresql.org> 2024-10-07 18:52 pgsql: Fix Y2038 issues with MyStartTime. Nathan Bossart <nathan@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