git-p4: return an empty list if a list config has no values
Signed-off-by: Lars Schneider <larsxschneider@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Lars Schneider committed
Sep 26, 2015 at 09:55 UTC
7960e70710a97b4d650531614b2839a907f79d95
1 file changed
+2
git-p4.py
+2
@@ -638,6 +638,8 @@ def gitConfigList(key):
638
if not _gitConfig.has_key(key):
639
s = read_pipe(["git", "config", "--get-all", key], ignore_error=True)
640
_gitConfig[key] = s.strip().split(os.linesep)
641
+ if _gitConfig[key] == ['']:
642
+ _gitConfig[key] = []
643
return _gitConfig[key]
644
645
def p4BranchesInGit(branchesAreInRemotes=True):