summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
Diffstat (limited to 'src/include')
-rw-r--r--src/include/common/jsonapi.h8
-rw-r--r--src/include/common/parse_manifest.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/src/include/common/jsonapi.h b/src/include/common/jsonapi.h
index f1ab17fc9f2..5d3ae4e09b8 100644
--- a/src/include/common/jsonapi.h
+++ b/src/include/common/jsonapi.h
@@ -89,7 +89,7 @@ typedef struct JsonIncrementalState JsonIncrementalState;
typedef struct JsonLexContext
{
char *input;
- int input_length;
+ size_t input_length;
int input_encoding;
char *token_start;
char *token_terminator;
@@ -158,7 +158,7 @@ extern JsonParseErrorType pg_parse_json(JsonLexContext *lex,
extern JsonParseErrorType pg_parse_json_incremental(JsonLexContext *lex,
JsonSemAction *sem,
char *json,
- int len,
+ size_t len,
bool is_last);
/* the null action object used for pure validation */
@@ -193,7 +193,7 @@ extern JsonParseErrorType json_count_array_elements(JsonLexContext *lex,
*/
extern JsonLexContext *makeJsonLexContextCstringLen(JsonLexContext *lex,
char *json,
- int len,
+ size_t len,
int encoding,
bool need_escapes);
@@ -219,6 +219,6 @@ extern char *json_errdetail(JsonParseErrorType error, JsonLexContext *lex);
*
* str argument does not need to be nul-terminated.
*/
-extern bool IsValidJsonNumber(const char *str, int len);
+extern bool IsValidJsonNumber(const char *str, size_t len);
#endif /* JSONAPI_H */
diff --git a/src/include/common/parse_manifest.h b/src/include/common/parse_manifest.h
index 0d04239c38d..2777b1e9d22 100644
--- a/src/include/common/parse_manifest.h
+++ b/src/include/common/parse_manifest.h
@@ -51,7 +51,7 @@ extern void json_parse_manifest(JsonManifestParseContext *context,
char *buffer, size_t size);
extern JsonManifestParseIncrementalState *json_parse_manifest_incremental_init(JsonManifestParseContext *context);
extern void json_parse_manifest_incremental_chunk(
- JsonManifestParseIncrementalState *incstate, char *chunk, int size,
+ JsonManifestParseIncrementalState *incstate, char *chunk, size_t size,
bool is_last);
extern void json_parse_manifest_incremental_shutdown(JsonManifestParseIncrementalState *incstate);