diff --git a/mercurial/crecord.py b/mercurial/crecord.py --- a/mercurial/crecord.py +++ b/mercurial/crecord.py @@ -451,7 +451,7 @@ def filterpatch(ui, chunks, chunkselecto # if there are no changed files if len(headers) == 0: - return [] + return [], {} uiheaders = [uiheader(h) for h in headers] # let user choose headers/hunks/lines, and mark their applied flags # accordingly diff --git a/tests/test-commit-interactive-curses.t b/tests/test-commit-interactive-curses.t --- a/tests/test-commit-interactive-curses.t +++ b/tests/test-commit-interactive-curses.t @@ -41,6 +41,10 @@ Committing some changes date: Thu Jan 01 00:00:00 1970 +0000 summary: a +Check that commit -i works with no changes + $ hg commit -i + no changes to record + Committing only one file $ echo "a" >> a