mirror of
https://github.com/json-c/json-c.git
synced 2026-03-21 22:19:07 +08:00
Remove superfluous NULL checks
This commit is contained in:
@@ -131,7 +131,7 @@ void json_tokener_free(struct json_tokener *tok)
|
||||
{
|
||||
json_tokener_reset(tok);
|
||||
if (tok->pb) printbuf_free(tok->pb);
|
||||
if (tok->stack) free(tok->stack);
|
||||
free(tok->stack);
|
||||
free(tok);
|
||||
}
|
||||
|
||||
@@ -901,7 +901,7 @@ struct json_object* json_tokener_parse_ex(struct json_tokener *tok,
|
||||
|
||||
#ifdef HAVE_SETLOCALE
|
||||
setlocale(LC_NUMERIC, oldlocale);
|
||||
if (oldlocale) free(oldlocale);
|
||||
free(oldlocale);
|
||||
#endif
|
||||
|
||||
if (tok->err == json_tokener_success)
|
||||
|
||||
Reference in New Issue
Block a user