[ovs-dev] [PATCH ovn 00/14] Pack of fixes for memory leaks.

Numan Siddique numans at ovn.org
Sun Nov 22 19:41:01 UTC 2020


On Fri, Nov 20, 2020 at 10:45 PM Dumitru Ceara <dceara at redhat.com> wrote:
>
> On 11/20/20 1:17 AM, Ilya Maximets wrote:
> > Found by Clang AddressSanitizer.
> >
> > All patches has correct and different 'Fixes' tags, so could be
> > backported to appropriate branches.
> >
> > Ilya Maximets (14):
> >   northd: Fix leaks of strings while formatting ecmp flows.
> >   test-ovn: Fix expression leak.
> >   actions: Fix leak of child ports in fwd group.
> >   actions: Fix leak of select group members.
> >   ofctrl: Fix leak of meter mod bands.
> >   pinctrl: Fix leak of DNS cache records.
> >   ovn-controller: Fix leak of pending ct zones.
> >   ovn-nbctl: Fix error leak on duplicated switch port.
> >   northd: Fix leak of dynamic string for fwd group ports.
> >   actions: Fix leak of dynamic string on fwd group encoding failure.
> >   ovn-nbctl: Fix leak of IPs while configuring NAT.
> >   ovn-nbctl: Fix IP leak on router NAT addition failure.
> >   ovn-nbctl: Fix IP leak on failure of lr policy addition.
> >   ovn-nbctl: Fix leak of array of new policies.
> >
> >  controller/ofctrl.c         | 1 +
> >  controller/ovn-controller.c | 2 +-
> >  controller/pinctrl.c        | 6 +++++-
> >  lib/actions.c               | 8 ++++++++
> >  northd/ovn-northd.c         | 9 ++++++++-
> >  tests/test-ovn.c            | 2 +-
> >  utilities/ovn-nbctl.c       | 8 +++++++-
> >  7 files changed, 31 insertions(+), 5 deletions(-)
> >
>
> Hi Ilya,
>
> Thanks for this!
>
> I only had a minor comment in patch 13/14 but except for that, for the
> series:
>
> Acked-by: Dumitru Ceara <dceara at redhat.com>

Thanks a lot Ilya for these fixes and Dumitru for the reviews.

I applied this patch series to master with the below addition to patch
10 -  actions: Fix leak of dynamic string on fwd group encoding
failure.

*******
diff --git a/lib/actions.c b/lib/actions.c
index 8f24946339..864ada85a8 100644
--- a/lib/actions.c
+++ b/lib/actions.c
@@ -3450,6 +3450,7 @@ encode_FWD_GROUP(const struct ovnact_fwd_group *fwd_group,

         /* Find the tunnel key of the logical port */
         if (!ep->lookup_port(ep->aux, port_name, &port_tunnel_key)) {
+            ds_destroy(&ds);
             return;
         }
         ds_put_format(&ds, ",bucket=");

***********************

I also backported to the branches.

All the patches were backported to branch-20.09
Patches 3 to 10 and 14 were applied to branch-20.06
Patches 3 to 10 were applied to branch-20.03.

Thanks
Numan



>
> Thanks,
> Dumitru
>
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>


More information about the dev mailing list