1
0
mirror of https://github.com/DaveGamble/cJSON synced 2024-12-23 15:12:04 +00:00

fix non-explicit cast

git-svn-id: http://svn.code.sf.net/p/cjson/code@52 e3330c51-1366-4df0-8b21-3ccf24e3d50e
This commit is contained in:
Dave Gamble 2013-02-09 12:55:11 +00:00
parent 02a1e544f7
commit 2c9474e9e3

View File

@ -438,7 +438,7 @@ static char *print_object(cJSON *item,int depth,int fmt)
/* Explicitly handle empty object case */
if (!numentries)
{
out=cJSON_malloc(fmt?depth+3:3);
out=(char*)cJSON_malloc(fmt?depth+3:3);
if (!out) return 0;
ptr=out;*ptr++='{';
if (fmt) {*ptr++='\n';for (i=0;i<depth-1;i++) *ptr++='\t';}