# HG changeset patch # User Yuya Nishihara # Date 2018-01-04 06:20:46 # Node ID 5fe6f946f1111e19c820823e538b38803070bc4a # Parent 84d0e99c063a0f26be5de5c8e5394f347ad7e519 log: allow matchfn to be non-null even if both --patch/--stat are off This makes the next patch slightly simpler. diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py --- a/mercurial/cmdutil.py +++ b/mercurial/cmdutil.py @@ -1725,7 +1725,8 @@ class changeset_printer(object): diffordiffstat(self.ui, self.repo, diffopts, prev, node, match=matchfn, stat=False, hunksfilterfn=hunksfilterfn) - self.ui.write("\n") + if stat or diff: + self.ui.write("\n") class jsonchangeset(changeset_printer): '''format changeset information.'''