[OpenWrt-Devel] Subject: [PATCH 1/1] blobmsg_json: allow to add full json files

Petr Štetiar ynezz at true.cz
Wed Jun 3 06:03:20 EDT 2020


Hi,

next time please do:

 $ git format-patch -s1 --subject-prefix "PATCH libubox" ...

as described in https://openwrt.org/submitting-patches

Adrian Panella <ianchi74 at outlook.com> [2020-02-22 20:11:28]:

> Current function "blobmsg_add_json_from_file" only adds json file if it is
> an object,  and it only returns the properties, not a full object attribute.
> This version allows to read any valid json file and returns the complete
> corresponding attribute.

...

>  }
>  

whitespace issue

> +bool blobmsg_add_json_file(struct blob_buf *b,  const char *name, const char *file)
> +{
> +	struct json_object *obj;
> +	bool ret;
> +	

whitespace issue

Apart from this whitespace nitpicks which I could fix by myself as well, I
would like to ask you for adding test case under tests directory for this new
function, so we can later assure on CI, that there are no memleaks or other
issues in this code and spot any regression later as well.

Please note, that test cases are not mandatory, but it is going to help merge
your valuable contribution faster :-) Thanks!

-- ynezz

_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list