summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--extras/volgen/Common.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/extras/volgen/Common.py b/extras/volgen/Common.py
index 10425096c85..298dee98943 100644
--- a/extras/volgen/Common.py
+++ b/extras/volgen/Common.py
@@ -74,7 +74,10 @@ def gfParser (volfile):
line = line.strip()
volfile_dict = {}
if re.match(r"[a-zA-Z0-9_]+", line):
- volfile_dict[line.split()[0]] = string.join (line.split()[1:], ' ') if line.split() > 1 else " "
+ if line.split() > 1:
+ volfile_dict[line.split()[0]] = string.join (line.split()[1:], ' ')
+ else:
+ volfile_dict[line.split()[0]] = " "
volume_array.append(volfile_dict)
return volume_array