mirror of https://github.com/akheron/jansson
* Fixed uninit variables
* Removed check less 0 with unsigned
This commit is contained in:
parent
b698ca13de
commit
18053cfdb9
|
@ -75,7 +75,7 @@ static int dump_indent(size_t flags, int depth, int space, json_dump_callback_t
|
||||||
static int dump_string(const char *str, size_t len, json_dump_callback_t dump, void *data, size_t flags)
|
static int dump_string(const char *str, size_t len, json_dump_callback_t dump, void *data, size_t flags)
|
||||||
{
|
{
|
||||||
const char *pos, *end, *lim;
|
const char *pos, *end, *lim;
|
||||||
int32_t codepoint;
|
int32_t codepoint = 0;
|
||||||
|
|
||||||
if(dump("\"", 1, data))
|
if(dump("\"", 1, data))
|
||||||
return -1;
|
return -1;
|
||||||
|
|
|
@ -145,7 +145,7 @@ const char *utf8_iterate(const char *buffer, size_t bufsize, int32_t *codepoint)
|
||||||
return buffer;
|
return buffer;
|
||||||
|
|
||||||
count = utf8_check_first(buffer[0]);
|
count = utf8_check_first(buffer[0]);
|
||||||
if(count <= 0)
|
if(count == 0)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if(count == 1)
|
if(count == 1)
|
||||||
|
|
Loading…
Reference in New Issue