Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
api idnode: fix compilation error and memory leak
  • Loading branch information
perexg committed Dec 5, 2016
1 parent 12c541e commit 2f8e948
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/api/api_idnode.c
Expand Up @@ -734,11 +734,13 @@ api_idnode_create( htsmsg_t **resp, idnode_t *in )
void
api_idnode_create_list( htsmsg_t **resp, htsmsg_t *list )
{
if (list == NULL)
if (list == NULL) {
htsmsg_destroy(list);
return;
}
if (*resp == NULL)
*resp = htsmsg_create_map();
htsmsg_add_str(*resp, "uuid", list);
htsmsg_add_msg(*resp, "uuid", list);
}

void api_idnode_init ( void )
Expand Down

0 comments on commit 2f8e948

Please sign in to comment.