summaryrefslogtreecommitdiffstats
path: root/extras/volgen/glusterfs-volgen.in
diff options
context:
space:
mode:
authorHarshavardhana Ranganath <harsha@gluster.com>2009-12-04 20:43:01 +0000
committerAnand V. Avati <avati@dev.gluster.com>2009-12-06 02:30:13 -0800
commit9cedbb537f648a38606d14c425caa952dd5d0049 (patch)
treea112195679838b52682cacb6eb85d83af22c9bad /extras/volgen/glusterfs-volgen.in
parenta2d7ca2ee22de61bf43525e4a8a2928ce6dd8851 (diff)
Fix critical argument validation bug found during initial testing.
Signed-off-by: Harshavardhana <harsha@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 437 (Fix critical argument validation check on Fedora11 systems) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=437
Diffstat (limited to 'extras/volgen/glusterfs-volgen.in')
-rwxr-xr-xextras/volgen/glusterfs-volgen.in10
1 files changed, 9 insertions, 1 deletions
diff --git a/extras/volgen/glusterfs-volgen.in b/extras/volgen/glusterfs-volgen.in
index 5d9c579cf..bd19d1227 100755
--- a/extras/volgen/glusterfs-volgen.in
+++ b/extras/volgen/glusterfs-volgen.in
@@ -27,10 +27,14 @@ def args2dict(args):
keyvalue = {}
for arg in args:
+ if int(arg.find(':')) == -1:
+ continue
first = arg.split(':')[0]
keyvalue[first] = []
for arg in args:
+ if int(arg.find(':')) == -1:
+ continue
first = arg.split(':')[0]
if arg.split(':')[1] not in keyvalue[first]:
if arg.split(':')[1][0] != '/':
@@ -43,7 +47,11 @@ def args2dict(args):
def args2array(args):
array = []
- array = args
+
+ for arg in args:
+ if int(arg.find(':')) == -1:
+ continue
+ array.append(arg)
return array