From fdd5b2b3b6ddeb602a88ebb57fefd9acdc2239ae Mon Sep 17 00:00:00 2001 From: jp9000 Date: Mon, 14 Apr 2014 13:46:07 -0700 Subject: [PATCH] Fix a few warnings with jansson --- deps/jansson/src/dump.c | 2 +- deps/jansson/src/error.c | 2 +- deps/jansson/src/load.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/deps/jansson/src/dump.c b/deps/jansson/src/dump.c index d347aae5f..26a1906e7 100644 --- a/deps/jansson/src/dump.c +++ b/deps/jansson/src/dump.c @@ -230,7 +230,7 @@ static int do_dump(const json_t *json, size_t flags, int depth, goto array_error; array->visited = 1; - n = json_array_size(json); + n = (int)json_array_size(json); if(dump("[", 1, data)) goto array_error; diff --git a/deps/jansson/src/error.c b/deps/jansson/src/error.c index a544a59fb..2ba8d82ce 100644 --- a/deps/jansson/src/error.c +++ b/deps/jansson/src/error.c @@ -56,7 +56,7 @@ void jsonp_error_vset(json_error_t *error, int line, int column, error->line = line; error->column = column; - error->position = position; + error->position = (int)position; vsnprintf(error->text, JSON_ERROR_TEXT_LENGTH, msg, ap); error->text[JSON_ERROR_TEXT_LENGTH - 1] = '\0'; diff --git a/deps/jansson/src/load.c b/deps/jansson/src/load.c index 2adaee80d..5d0d1efcd 100644 --- a/deps/jansson/src/load.c +++ b/deps/jansson/src/load.c @@ -171,7 +171,7 @@ static int stream_get(stream_t *stream, json_error_t *error) /* multi-byte UTF-8 sequence */ int i, count; - count = utf8_check_first(c); + count = (int)utf8_check_first(c); if(!count) goto out; @@ -900,7 +900,7 @@ static json_t *parse_json(lex_t *lex, size_t flags, json_error_t *error) if(error) { /* Save the position even though there was no error */ - error->position = lex->stream.position; + error->position = (int)lex->stream.position; } return result;