summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTodd Willey <xtoddx@gmail.com>2012-01-18 14:27:09 -0500
committerTodd Willey <xtoddx@gmail.com>2012-01-18 14:32:56 -0500
commit6bb8944112f07c3328186f4d2c53c3661d165f9d (patch)
tree3c68abf2f8dc779820625f97cc6df22f5fe4d4ea
parent7f3ddead0483a36c60a3c8034e0082779e17adc9 (diff)
downloadnova-6bb8944112f07c3328186f4d2c53c3661d165f9d.tar.gz
nova-6bb8944112f07c3328186f4d2c53c3661d165f9d.tar.xz
nova-6bb8944112f07c3328186f4d2c53c3661d165f9d.zip
Fix disassociating of auto assigned floating ips.
Also makes adds passing True to the disassociate/deallocate functions use a kwarg so the meaning is more apparent. Fixes bug #918358. Change-Id: Ie88d19456ffe0fa5f7c7bba79b572672db96c766
-rw-r--r--nova/network/manager.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/nova/network/manager.py b/nova/network/manager.py
index 68440be2d..9d6009e0d 100644
--- a/nova/network/manager.py
+++ b/nova/network/manager.py
@@ -295,10 +295,12 @@ class FloatingIP(object):
# disassociate floating ips related to fixed_ip
for floating_ip in floating_ips:
address = floating_ip['address']
- self.disassociate_floating_ip(context, address, True)
+ self.disassociate_floating_ip(context, address,
+ affect_auto_assigned=True)
# deallocate if auto_assigned
if floating_ip['auto_assigned']:
- self.release_floating_ip(context, address, True)
+ self.deallocate_floating_ip(context, address,
+ affect_auto_assigned=True)
# call the next inherited class's deallocate_for_instance()
# which is currently the NetworkManager version