diff options
Diffstat (limited to 'builtin-diff-files.c')
-rw-r--r-- | builtin-diff-files.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/builtin-diff-files.c b/builtin-diff-files.c index 5d4a5c5828..3ee26059fc 100644 --- a/builtin-diff-files.c +++ b/builtin-diff-files.c @@ -47,5 +47,9 @@ int cmd_diff_files(int argc, const char **argv, const char *prefix) if (rev.pending.nr || rev.min_age != -1 || rev.max_age != -1) usage(diff_files_usage); + if (read_cache() < 0) { + perror("read_cache"); + return -1; + } return run_diff_files(&rev, silent); } |