[ovs-dev] [PATCH 11/11] ovn-nbctl: Fix mem leak in nbctl_lrp_set_gateway_chassis().

Jakub Sitnicki jkbs at redhat.com
Tue Jul 17 13:34:15 UTC 2018


Fix fall-out from applying a semantic patch to propagate the error.

Signed-off-by: Jakub Sitnicki <jkbs at redhat.com>
---
 ovn/utilities/ovn-nbctl.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/ovn/utilities/ovn-nbctl.c b/ovn/utilities/ovn-nbctl.c
index 27e3151a8..12845a035 100644
--- a/ovn/utilities/ovn-nbctl.c
+++ b/ovn/utilities/ovn-nbctl.c
@@ -3473,6 +3473,7 @@ nbctl_lrp_set_gateway_chassis(struct ctl_context *ctx)
     error = gc_by_name_or_uuid(ctx, gc_name, false, &existing_gc);
     if (error) {
         ctx->error = error;
+        free(gc_name);
         return;
     }
     if (existing_gc) {
-- 
2.14.4



More information about the dev mailing list