pgsql: Fix a couple of cases of JSON output. - Mailing list pgsql-committers

From Andrew Dunstan
Subject pgsql: Fix a couple of cases of JSON output.
Date
Msg-id E1RzZUv-0001jm-Nc@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Fix a couple of cases of JSON output.

First, as noted by Itagaki Takahiro, a datum of type JSON doesn't
need to be escaped. Second, ensure that numeric output not in
the form of a legal JSON number is quoted and escaped.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/83fcaffea2b55152e45fdcaf3fdaf4c0c89f65ce

Modified Files
--------------
src/backend/utils/adt/json.c       |   25 +++++++++++++++++++++----
src/test/regress/expected/json.out |   30 ++++++++++++++++++++++++++++++
src/test/regress/sql/json.sql      |   15 +++++++++++++++
3 files changed, 66 insertions(+), 4 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Fix regex back-references that are directly quantified with *.
Next
From: Tom Lane
Date:
Subject: pgsql: Don't reject threaded Python on FreeBSD.