[ovs-dev,14/14] datapath-windows: Cleanup Vxlan.c

Message ID 20180709134056.7060-15-aserdean@ovn.org
State Changes Requested
Headers show
Series
  • Cleanup datapath-windows
Related show

Commit Message

Alin Gabriel Serdean July 9, 2018, 1:40 p.m.
Assign variables directly instead of reassigning them after.

Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
---
 datapath-windows/ovsext/Vxlan.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Patch

diff --git a/datapath-windows/ovsext/Vxlan.c b/datapath-windows/ovsext/Vxlan.c
index 09809d397..2ec0e0df7 100644
--- a/datapath-windows/ovsext/Vxlan.c
+++ b/datapath-windows/ovsext/Vxlan.c
@@ -66,10 +66,10 @@  OvsIsTunnelFilterCreated(POVS_SWITCH_CONTEXT switchContext,
 
         head = &(switchContext->portNoHashArray[hash & OVS_VPORT_MASK]);
         LIST_FORALL_SAFE(head, link, next) {
-            POVS_VPORT_ENTRY vport = NULL;
-            POVS_VXLAN_VPORT vxlanPort = NULL;
-            vport = CONTAINING_RECORD(link, OVS_VPORT_ENTRY, portNoLink);
-            vxlanPort = (POVS_VXLAN_VPORT)vport->priv;
+            POVS_VPORT_ENTRY vport =
+                CONTAINING_RECORD(link, OVS_VPORT_ENTRY, portNoLink);
+
+            POVS_VXLAN_VPORT vxlanPort = (POVS_VXLAN_VPORT)vport->priv;
             if (vxlanPort) {
                 if ((udpPortDest == vxlanPort->dstPort)) {
                     /* The VXLAN tunnel was already created. */