aboutsummaryrefslogtreecommitdiff
path: root/ipsutils
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2013-07-12 08:52:24 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2013-07-12 08:52:24 -0400
commit8dd1b416a62c78ec3c1bff371486aee59740b45d (patch)
treed3d5ca01f4ea7df472532841ca93d80b802ad29e /ipsutils
parentc547a12504f3c68a17f24d628d69336c8d1c88c4 (diff)
downloadipsutils-8dd1b416a62c78ec3c1bff371486aee59740b45d.tar.gz
Bugfix: Strip whitespace from end of line to prevent random errors during build
Diffstat (limited to 'ipsutils')
-rw-r--r--ipsutils/config.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ipsutils/config.py b/ipsutils/config.py
index 96d742d..eed142c 100644
--- a/ipsutils/config.py
+++ b/ipsutils/config.py
@@ -57,7 +57,7 @@ class Config(object):
for line in file(ipsfile).readlines():
parts = shlex.split(line)
if key + ":" in parts:
- key_dict[key] = line[line.find(':')+1:].lstrip(' ').rstrip('\n')
+ key_dict[key] = line[line.find(':')+1:].lstrip(' ').rstrip('\n').rstrip(' ')
#Drop using the original file in favor of a StringIO buffer
#Because we need room to breathe without rewriting the file
@@ -77,7 +77,7 @@ class Config(object):
for line in ipsfile_output:
parts = shlex.split(line)
if key + ":" in parts:
- key_dict[key] = line[line.find(':')+1:].lstrip(' ').rstrip('\n')
+ key_dict[key] = line[line.find(':')+1:].lstrip(' ').rstrip('\n').rstrip(' ')
#Parse user defined scripts by section and store them in script_dict
found_data = False