summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Erdfelt <johannes.erdfelt@rackspace.com>2012-02-07 15:49:13 +0000
committerJohannes Erdfelt <johannes.erdfelt@rackspace.com>2012-02-07 15:49:13 +0000
commitc716c94d1db26faa59332340e9eabe03b3d41d1b (patch)
tree90a648460ae754e275df1bef3322e6c1253c79d1
parentde23221007cc687533c86f0de217c7d0b6fb523f (diff)
downloadnova-c716c94d1db26faa59332340e9eabe03b3d41d1b.tar.gz
nova-c716c94d1db26faa59332340e9eabe03b3d41d1b.tar.xz
nova-c716c94d1db26faa59332340e9eabe03b3d41d1b.zip
Fix support for --flagfile argument
Recent changes broke support for the --flagfile argument. It would attempt to find the argument and then pull off the filename portion, but it would only skip one letter, instead of the full argument name. The resulting error would be: Change-Id: Ic252b0c778774a7ea3e24a9ed8b182deb5987f65 OSError: [Errno 2] No such file or directory: 'lagfile=../nova.conf'
-rw-r--r--nova/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/nova/utils.py b/nova/utils.py
index a98897d82..f9ffe3adc 100644
--- a/nova/utils.py
+++ b/nova/utils.py
@@ -325,7 +325,7 @@ def default_flagfile(filename='nova.conf', args=None):
args = sys.argv
for arg in args:
if arg.find('flagfile') != -1:
- return arg[arg.index('flagfile') + 1:]
+ return arg[arg.index('flagfile') + len('flagfile') + 1:]
else:
if not os.path.isabs(filename):
# turn relative filename into an absolute path