]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Fix backpatching error in commit 55c88079
authorAndrew Dunstan <andrew@dunslane.net>
Mon, 1 Dec 2014 17:48:35 +0000 (12:48 -0500)
committerAndrew Dunstan <andrew@dunslane.net>
Mon, 1 Dec 2014 17:48:35 +0000 (12:48 -0500)
src/backend/utils/adt/json.c

index 0873bb3ce15c11a3dd08bb11ab2877ff403b8758..ef5608deb827d242ccd464d7781ec32f5d21b965 100644 (file)
@@ -1363,7 +1363,7 @@ datum_to_json(Datum val, bool is_null, StringInfo result,
                         * Don't call escape_json for a non-key if it's a valid JSON
                         * number.
                         */
-                       if (!key_scalar && IsValidJsonNumber(outputstr, strlen(outputstr)))
+                       if (IsValidJsonNumber(outputstr, strlen(outputstr)))
                                appendStringInfoString(result, outputstr);
                        else
                                escape_json(result, outputstr);