diff options
Diffstat (limited to 'src/common/jsonapi.c')
-rw-r--r-- | src/common/jsonapi.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/common/jsonapi.c b/src/common/jsonapi.c index 7df231c3851..aa917d0fc9d 100644 --- a/src/common/jsonapi.c +++ b/src/common/jsonapi.c @@ -54,7 +54,7 @@ typedef enum /* contexts of JSON parser */ static inline JsonParseErrorType json_lex_string(JsonLexContext *lex); static inline JsonParseErrorType json_lex_number(JsonLexContext *lex, char *s, - bool *num_err, int *total_len); + bool *num_err, int *total_len); static inline JsonParseErrorType parse_scalar(JsonLexContext *lex, JsonSemAction *sem); static JsonParseErrorType parse_object_field(JsonLexContext *lex, JsonSemAction *sem); static JsonParseErrorType parse_object(JsonLexContext *lex, JsonSemAction *sem); @@ -179,7 +179,7 @@ JsonParseErrorType pg_parse_json(JsonLexContext *lex, JsonSemAction *sem) { JsonTokenType tok; - JsonParseErrorType result; + JsonParseErrorType result; /* get the initial token */ result = json_lex(lex); @@ -198,7 +198,7 @@ pg_parse_json(JsonLexContext *lex, JsonSemAction *sem) result = parse_array(lex, sem); break; default: - result = parse_scalar(lex, sem); /* json can be a bare scalar */ + result = parse_scalar(lex, sem); /* json can be a bare scalar */ } if (result == JSON_SUCCESS) @@ -220,7 +220,7 @@ json_count_array_elements(JsonLexContext *lex, int *elements) { JsonLexContext copylex; int count; - JsonParseErrorType result; + JsonParseErrorType result; /* * It's safe to do this with a shallow copy because the lexical routines @@ -252,7 +252,7 @@ json_count_array_elements(JsonLexContext *lex, int *elements) } } result = lex_expect(JSON_PARSE_ARRAY_NEXT, ©lex, - JSON_TOKEN_ARRAY_END); + JSON_TOKEN_ARRAY_END); if (result != JSON_SUCCESS) return result; @@ -527,7 +527,7 @@ json_lex(JsonLexContext *lex) { char *s; int len; - JsonParseErrorType result; + JsonParseErrorType result; /* Skip leading whitespace. */ s = lex->token_terminator; @@ -1123,8 +1123,8 @@ json_errdetail(JsonParseErrorType error, JsonLexContext *lex) static char * extract_token(JsonLexContext *lex) { - int toklen = lex->token_terminator - lex->token_start; - char *token = palloc(toklen + 1); + int toklen = lex->token_terminator - lex->token_start; + char *token = palloc(toklen + 1); memcpy(token, lex->token_start, toklen); token[toklen] = '\0'; |