From dc922da0868e789a8d3322420ccd124460b63db3 Mon Sep 17 00:00:00 2001
From: Iustin Pop <iustin@google.com>
Date: Tue, 4 Aug 2009 14:33:37 +0200
Subject: [PATCH] Fix instance import net option

This is identical to dc30b0e4 but applied to gnt-backup. Thanks to user
ocaner for catching it.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
---
 scripts/gnt-backup | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/gnt-backup b/scripts/gnt-backup
index e78abbaee..467b37d0a 100755
--- a/scripts/gnt-backup
+++ b/scripts/gnt-backup
@@ -102,7 +102,7 @@ def ImportInstance(opts, args):
     except ValueError, err:
       raise errors.OpPrereqError("Invalid NIC index passed: %s" % str(err))
     nics = [{}] * nic_max
-    for nidx, ndict in opts.nics.items():
+    for nidx, ndict in opts.nics:
       nidx = int(nidx)
       nics[nidx] = ndict
   elif opts.no_nics:
-- 
GitLab