ubus: Fix memleak in examples/client in case of failure

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
This commit is contained in:
Hans Dedecker 2015-04-28 16:07:28 +02:00 committed by Felix Fietkau
parent 7798d56301
commit 38174a05a5

View file

@ -118,6 +118,7 @@ static void test_count(struct uloop_timeout *timeout)
blobmsg_add_string(&b, "string", s);
if (ubus_lookup_id(ctx, "test", &id)) {
free(s);
fprintf(stderr, "Failed to look up test object\n");
return;
}