Detect garbage near EOF in json_loadf() and json_load_file()