Commit dc30b0e4 authored by Iustin Pop's avatar Iustin Pop
Browse files

Fix the --net option to gnt-instance add

Similar to the --disk fixes a while ago, --net is broken too. This patch
fixes it.

Reviewed-by: imsnah
parent 6b405598
......@@ -321,7 +321,7 @@ def AddInstance(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:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment