X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fafb-api-v3.c;fp=src%2Fafb-api-v3.c;h=02853b1283ebf5005117d5e511a89b30f27da3c3;hb=9c2e6e45d4c9745c4702ac1992a0cb086e99fb0b;hp=1bda6b08233ec2ffe990f08800a99bdc9e09715c;hpb=f96bbb49cc9bcd81693300191cf7a01b879fd83d;p=src%2Fapp-framework-binder.git diff --git a/src/afb-api-v3.c b/src/afb-api-v3.c index 1bda6b08..02853b12 100644 --- a/src/afb-api-v3.c +++ b/src/afb-api-v3.c @@ -239,6 +239,9 @@ void afb_api_v3_unref(struct afb_api_v3 *api) { if (api && !__atomic_sub_fetch(&api->refcount, 1, __ATOMIC_RELAXED)) { afb_export_destroy(api->export); + while (api->count) + free(api->verbs[--api->count]); + free(api->verbs); free(api); } }