From: houranled Date: Thu, 25 Sep 2025 09:50:51 +0000 (+0800) Subject: Use correct parameter name : rename 'value' to 'key'. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e52954bf07120615ee91e39ab068d8c503a0eab9;p=thirdparty%2Fcups.git Use correct parameter name : rename 'value' to 'key'. --- diff --git a/cups/json.c b/cups/json.c index dae2a86ce9..584d3f27a1 100644 --- a/cups/json.c +++ b/cups/json.c @@ -1361,10 +1361,10 @@ cupsJSONNew(cups_json_t *parent, // I - Parent JSON node or `NULL` for a root n cups_json_t * // O - JSON node cupsJSONNewKey(cups_json_t *parent, // I - Parent JSON node or `NULL` for a root node cups_json_t *after, // I - Previous sibling node or `NULL` to append to the end - const char *value) // I - Key string + const char *key) // I - Key string { cups_json_t *node; // JSON node - char *s = strdup(value); // Key string + char *s = strdup(key); // Key string if (!s) diff --git a/cups/json.h b/cups/json.h index 699500727b..df7bad6350 100644 --- a/cups/json.h +++ b/cups/json.h @@ -61,7 +61,7 @@ extern cups_json_t *cupsJSONImportString(const char *s) _CUPS_PUBLIC; extern cups_json_t *cupsJSONImportURL(const char *url, time_t *last_modified) _CUPS_PUBLIC; extern cups_json_t *cupsJSONNew(cups_json_t *parent, cups_json_t *after, cups_jtype_t type) _CUPS_PUBLIC; -extern cups_json_t *cupsJSONNewKey(cups_json_t *parent, cups_json_t *after, const char *value) _CUPS_PUBLIC; +extern cups_json_t *cupsJSONNewKey(cups_json_t *parent, cups_json_t *after, const char *key) _CUPS_PUBLIC; extern cups_json_t *cupsJSONNewNumber(cups_json_t *parent, cups_json_t *after, double number) _CUPS_PUBLIC; extern cups_json_t *cupsJSONNewString(cups_json_t *parent, cups_json_t *after, const char *value) _CUPS_PUBLIC;