diff options
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/diff.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/diff.c b/builtin/diff.c index 1a1149eed4..5e7c6428c9 100644 --- a/builtin/diff.c +++ b/builtin/diff.c @@ -90,7 +90,8 @@ static int builtin_diff_b_f(struct rev_info *revs, blob[0]->mode, canon_mode(st.st_mode), &blob[0]->item->oid, &null_oid, 1, 0, - path, path); + blob[0]->path ? blob[0]->path : path, + path); diffcore_std(&revs->diffopt); diff_flush(&revs->diffopt); return 0; |