Skip to content

Commit 874c665

Browse files
JasonJayPowersergio-correia
authored andcommitted
Fix memory leak
1 parent 749a368 commit 874c665

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/misc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ zero(void *mem, size_t len)
4747
bool
4848
handle_zip_enc(json_t *json, const void *in, size_t len, void **data, size_t *datalen)
4949
{
50-
json_t *prt = NULL;
50+
json_auto_t *prt = NULL;
5151
char *z = NULL;
5252
const jose_hook_alg_t *a = NULL;
5353
jose_io_auto_t *zip = NULL;
@@ -85,7 +85,7 @@ handle_zip_enc(json_t *json, const void *in, size_t len, void **data, size_t *da
8585
bool
8686
zip_in_protected_header(json_t *json)
8787
{
88-
json_t *prt = NULL;
88+
json_auto_t *prt = NULL;
8989
char *z = NULL;
9090

9191
prt = json_object_get(json, "protected");

0 commit comments

Comments
 (0)