cJSON

mirror of Dave's cJSON
git clone git://git.thc420.xyz/cJSON
Log | Files | Refs | README | LICENSE

commit ef34500693e8c4a2849d41a4bd66fd19c9ec46c2
parent b0dfcde04c29d59d0c480eb4f983821df5b49446
Author: Max Bruckner <max@maxbruckner.de>
Date:   Tue, 28 Mar 2017 17:29:12 +0200

cJSON_SetNumberHelper: Fix valueint, closes #138

Thanks @mmkeeper

Diffstat:
McJSON.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cJSON.c b/cJSON.c @@ -228,7 +228,7 @@ CJSON_PUBLIC(double) cJSON_SetNumberHelper(cJSON *object, double number) } else { - object->valueint = cJSON_Number; + object->valueint = (int)number; } return object->valuedouble = number;