diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2018-12-10 15:07:33 +0100 |
---|---|---|
committer | Romain Forlot <romain.forlot@iot.bzh> | 2018-12-13 11:33:40 +0100 |
commit | 9728c33be05a20143e8f2b333f93d6cec448ad32 (patch) | |
tree | 53ce4dc45166c372f08b134cf28ff6b7b9e5f1ea | |
parent | fd9b8c158b8542fc3daf654df2d936248ace76a6 (diff) |
little memleak fix.
Change-Id: I9288ef2f2f9d37de993164dd454fc75b69f44abf
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
-rw-r--r-- | src/aft.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -251,6 +251,7 @@ int afbBindingEntry(afb_api_t apiHandle) { char *dirList, *afTestRootDir, *path; const char *envDirList = NULL, *configPath = NULL, *bindingRootDir = NULL; json_object *settings = afb_api_settings(apiHandle), *bpath = NULL; + CtlConfigT *ctrlConfig = NULL; AFB_API_DEBUG(apiHandle, "Controller in afbBindingEntry"); @@ -290,6 +291,8 @@ int afbBindingEntry(afb_api_t apiHandle) { return ERROR; } + ctrlConfig = CtrlLoadConfigFile(apiHandle, configPath); free(afTestRootDir); - return CtrlCreateApi(apiHandle, CtrlLoadConfigFile(apiHandle, configPath)); + free(dirList); + return CtrlCreateApi(apiHandle, ctrlConfig); } |