[RFC PATCH v3 3/5] lib/audit_logging: avoid freeing unallocated json value
Gary Lockyer
gary at catalyst.net.nz
Thu Jul 12 19:24:20 UTC 2018
Looks good will include it in the API changes. Could you send it through
as an attachment.
Gary
On 12/07/18 19:04, Philipp Gesang via samba-technical wrote:
> json_free() has no effect on the empty json value so the call is
> redundant.
>
> Signed-off-by: Philipp Gesang <philipp.gesang at intra2net.com>
> ---
> lib/audit_logging/audit_logging.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/lib/audit_logging/audit_logging.c b/lib/audit_logging/audit_logging.c
> index d5fbad086d4..04eeaff011a 100644
> --- a/lib/audit_logging/audit_logging.c
> +++ b/lib/audit_logging/audit_logging.c
> @@ -981,7 +981,6 @@ struct json_object json_get_array(
> if (json_is_invalid(object)) {
> DBG_ERR("Invalid JSON object, unable to get array [%s]\n",
> name);
> - json_free(&array);
> return array;
> }
>
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20180713/f76d02d4/signature.sig>
More information about the samba-technical
mailing list