Mercurial > hg
comparison mercurial/url.py @ 43910:c41ed5d4f770
config: close file even if we fail to read it
If we get an exception from cfg.read(), we would not close the file
before this patch. This patch uses a context manager to make sure we
close it.
Differential Revision: https://phab.mercurial-scm.org/D7626
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Wed, 11 Dec 2019 15:06:09 -0800 |
parents | 9f70512ae2cf |
children | 9d2b2df2c2ba |
comparison
equal
deleted
inserted
replaced
43909:dbaf9aabfb69 | 43910:c41ed5d4f770 |
---|