mirror of
https://github.com/openvswitch/ovs
synced 2025-10-11 13:57:52 +00:00
dpif-netdev: Fix use-after-free error in reconfigure_datapath().
Found by Coverity. Reported-at: https://scan3.coverity.com/reports.htm#v16889/p10449/fileInstanceId=14762915&defectInstanceId=4305352&mergedDefectId=180430 Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2009, 2010, 2011, 2012, 2013, 2014, 2016 Nicira, Inc.
|
||||
* Copyright (c) 2009, 2010, 2011, 2012, 2013, 2014, 2016, 2017 Nicira, Inc.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -3456,7 +3456,8 @@ reconfigure_datapath(struct dp_netdev *dp)
|
||||
/* We only reconfigure the ports that we determined above, because they're
|
||||
* not being used by any pmd thread at the moment. If a port fails to
|
||||
* reconfigure we remove it from the datapath. */
|
||||
HMAP_FOR_EACH (port, node, &dp->ports) {
|
||||
struct dp_netdev_port *next_port;
|
||||
HMAP_FOR_EACH_SAFE (port, next_port, node, &dp->ports) {
|
||||
int err;
|
||||
|
||||
if (!port->need_reconfigure) {
|
||||
|
Reference in New Issue
Block a user