pgsql: Prevent CRLF conversion of inputs in json_parser test module - Mailing list pgsql-committers

From Andrew Dunstan
Subject pgsql: Prevent CRLF conversion of inputs in json_parser test module
Date
Msg-id E1sRITw-0012U5-E8@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Prevent CRLF conversion of inputs in json_parser test module

Do this by opening the file in PG_BINARY_R mode. This prevents us from
getting wrong byte count from stat().

Per complaint from Andres Freund

Discussion: https://postgr.es/m/20240707052030.r77hbdkid3mwksop@awork3.anarazel.de

Backpatch to rlease 17 where this code was introduced

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/f7bd0a381de12a5c309f3c19d8c966b77e87cff3

Modified Files
--------------
src/test/modules/test_json_parser/test_json_parser_incremental.c | 2 +-
src/test/modules/test_json_parser/test_json_parser_perf.c        | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Remove new XML test cases added by e7192486d.
Next
From: Andrew Dunstan
Date:
Subject: pgsql: Prevent CRLF conversion of inputs in json_parser test module