summaryrefslogtreecommitdiff
path: root/src/migration-scripts/nat/5-to-6
diff options
context:
space:
mode:
Diffstat (limited to 'src/migration-scripts/nat/5-to-6')
-rwxr-xr-xsrc/migration-scripts/nat/5-to-65
1 files changed, 3 insertions, 2 deletions
diff --git a/src/migration-scripts/nat/5-to-6 b/src/migration-scripts/nat/5-to-6
index de3830582..c83b93d84 100755
--- a/src/migration-scripts/nat/5-to-6
+++ b/src/migration-scripts/nat/5-to-6
@@ -51,8 +51,9 @@ for direction in ['source', 'destination']:
for iface in ['inbound-interface','outbound-interface']:
if config.exists(base + [iface]):
tmp = config.return_value(base + [iface])
- config.delete(base + [iface])
- config.set(base + [iface, 'interface-name'], value=tmp)
+ if tmp:
+ config.delete(base + [iface])
+ config.set(base + [iface, 'interface-name'], value=tmp)
try:
with open(file_name, 'w') as f: