From 9d76ac09613eaf0eb78a31add19bec16e048a59a Mon Sep 17 00:00:00 2001 From: "Ruben S. Montero" Date: Tue, 22 Apr 2014 12:24:21 +0200 Subject: [PATCH] Reset current network when the map is updated --- src/vnm/FixedLeases.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vnm/FixedLeases.cc b/src/vnm/FixedLeases.cc index 61236c3db1..bdb01f6f4e 100644 --- a/src/vnm/FixedLeases.cc +++ b/src/vnm/FixedLeases.cc @@ -140,6 +140,8 @@ int FixedLeases::add(const string& ip, const string& mac, int vid, n_used++; } + current = leases.begin(); + return rc; error_no_ip_mac: @@ -217,6 +219,8 @@ int FixedLeases::remove(const string& ip, string& error_msg) leases.erase(it); + current = leases.begin(); + return rc;