Skip to content

Commit 7b596d3

Browse files
committed
Fix message upon edit from diffstat without patch
1 parent 80ad85c commit 7b596d3

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

NEWS.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ Bug fixes:
88

99
- Fix various issues with `diff.noprefix` and `--no-prefix`.
1010
- Fix `Ctrl-C` behavior within the Readline prompt. (#1342)
11+
- Fix message upon edit from diffstat without patch.
1112

1213
Improvements:
1314

src/diff.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -756,7 +756,7 @@ diff_common_edit(struct view *view, enum request request, struct line *line)
756756
lineno = diff_get_lineno(view, line, false);
757757
}
758758

759-
if (!file) {
759+
if (!file || !*file) {
760760
report("Nothing to edit");
761761
return REQ_NONE;
762762
}

0 commit comments

Comments
 (0)