From ee9516c87345c4f5edf5e9722bd4cabeaf704f98 Mon Sep 17 00:00:00 2001
From: Guido Trotter <ultrotter@google.com>
Date: Fri, 8 Feb 2013 08:44:48 +0100
Subject: [PATCH] ConfigData: run UpgradeConfig on network objects

Although this does nothing for now, running it is safe, and consistent
with how other objects behave.

Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
---
 lib/objects.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/objects.py b/lib/objects.py
index f8667e343..e3ff4ac4e 100644
--- a/lib/objects.py
+++ b/lib/objects.py
@@ -499,6 +499,8 @@ class ConfigData(ConfigObject):
         self.cluster.drbd_usermode_helper = constants.DEFAULT_DRBD_HELPER
     if self.networks is None:
       self.networks = {}
+    for network in self.networks.values():
+      network.UpgradeConfig()
 
 
 class NIC(ConfigObject):
-- 
GitLab