ha: Fix assignment of IP addresses if multiple pools are defined
authorTobias Brunner <tobias@strongswan.org>
Thu, 13 Oct 2016 16:39:09 +0000 (18:39 +0200)
committerTobias Brunner <tobias@strongswan.org>
Wed, 25 Jan 2017 11:28:34 +0000 (12:28 +0100)
Fixes #2146.

src/libcharon/plugins/ha/ha_attribute.c

index b20ef87..34d6efc 100644 (file)
@@ -215,8 +215,12 @@ METHOD(attribute_provider_t, acquire_address, host_t*,
                }
                if (offset == -1)
                {
-                       DBG1(DBG_CFG, "no address left in HA pool '%s' belonging to"
-                                "a responsible segment", name);
+                       DBG1(DBG_CFG, "no address belonging to a responsible segment left "
+                                "in HA pool '%s'", name);
+               }
+               else
+               {
+                       break;
                }
        }
        this->mutex->unlock(this->mutex);