diff options
author | mathieui <mathieui@mathieui.net> | 2014-04-24 21:12:48 +0200 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2014-04-24 21:12:48 +0200 |
commit | 4de2dfc72ba6ea451c9dba8b938a861b4f065a35 (patch) | |
tree | 1adac3994b8cfaa05c9a7568792b5f6531c1f08d | |
parent | 1349f297f5a76b6f17ab43ec24f7454f38e28a4a (diff) | |
download | poezio-4de2dfc72ba6ea451c9dba8b938a861b4f065a35.tar.gz poezio-4de2dfc72ba6ea451c9dba8b938a861b4f065a35.tar.bz2 poezio-4de2dfc72ba6ea451c9dba8b938a861b4f065a35.tar.xz poezio-4de2dfc72ba6ea451c9dba8b938a861b4f065a35.zip |
Fix a bug in the config._parse_file function (traceback when parsing empty files)
-rw-r--r-- | src/config.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/config.py b/src/config.py index 34db0477..354c3447 100644 --- a/src/config.py +++ b/src/config.py @@ -256,7 +256,7 @@ class Config(RawConfigParser): sections[current_section] = [current_line, current_line] current_line += 1 - if not duplicate_section: + if not duplicate_section and current_section: sections[current_section][1] = current_line return (sections, lines_before) |