cJSON

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

commit d606cbbc641f1f8f5942f3318141c59a2576d126
parent be749d7efa7c9021da746e685bd6dec79f9dd99b
Author: Max Bruckner <max@maxbruckner.de>
Date:   Sun, 16 Dec 2018 11:10:06 +0100

Merge pull request #317 from yuta-oxo/fix_sort_list

fix bug: sort_list() returns strange results
Diffstat:
McJSON_Utils.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cJSON_Utils.c b/cJSON_Utils.c @@ -510,7 +510,7 @@ static cJSON *sort_list(cJSON *list, const cJSON_bool case_sensitive) while ((first != NULL) && (second != NULL)) { cJSON *smaller = NULL; - if (compare_strings((unsigned char*)first->string, (unsigned char*)second->string, false) < 0) + if (compare_strings((unsigned char*)first->string, (unsigned char*)second->string, case_sensitive) < 0) { smaller = first; }