[ovs-dev] [memory fixes 1/6] ofproto: Fix use-after-free error in facet_revalidate().
Justin Pettit
jpettit at nicira.com
Mon Dec 13 21:21:34 UTC 2010
Looks good.
--Justin
On Dec 13, 2010, at 1:10 PM, Ben Pfaff wrote:
> Found by valgrind.
> ---
> ofproto/ofproto.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/ofproto/ofproto.c b/ofproto/ofproto.c
> index 255df65..52f3c8a 100644
> --- a/ofproto/ofproto.c
> +++ b/ofproto/ofproto.c
> @@ -2478,8 +2478,6 @@ facet_revalidate(struct ofproto *ofproto, struct facet *facet)
> facet_flush_stats(ofproto, facet);
> }
>
> - ofpbuf_delete(odp_actions);
> -
> /* Update 'facet' now that we've taken care of all the old state. */
> facet->tags = ctx.tags;
> facet->nf_flow.output_iface = ctx.nf_output_iface;
> @@ -2497,6 +2495,8 @@ facet_revalidate(struct ofproto *ofproto, struct facet *facet)
> facet->used = new_rule->created;
> }
>
> + ofpbuf_delete(odp_actions);
> +
> return true;
> }
>
> --
> 1.7.1
>
>
> _______________________________________________
> dev mailing list
> dev at openvswitch.org
> http://openvswitch.org/mailman/listinfo/dev_openvswitch.org
More information about the dev
mailing list