diff options
author | Junio C Hamano <junkio@cox.net> | 2007-02-24 02:20:13 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2007-02-24 02:20:13 -0800 |
commit | efdfd6c8d418a2c12f31cacb50fa8a91b2b868c8 (patch) | |
tree | 93a5eea7b3887a2a58583bf249f1d556019ba418 /builtin-diff.c | |
parent | d516c2d11945cf13ed3d961fa63817c60b7a566b (diff) | |
parent | b4e1e4a787d3771f617182b3344dcdd9224bd0cb (diff) | |
download | git-efdfd6c8d418a2c12f31cacb50fa8a91b2b868c8.tar.gz |
Evil Merge branch 'jc/status' (early part) into js/diff-ni
* 'jc/status' (early part):
run_diff_{files,index}(): update calling convention.
update-index: do not die too early in a read-only repository.
git-status: do not be totally useless in a read-only repository.
This is to resolve semantic conflict (which is not textual) that
changes the calling convention of run_diff_files() early.
Diffstat (limited to 'builtin-diff.c')
-rw-r--r-- | builtin-diff.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/builtin-diff.c b/builtin-diff.c index 54bbf025d9..45faa2067a 100644 --- a/builtin-diff.c +++ b/builtin-diff.c @@ -117,6 +117,10 @@ static int builtin_diff_index(struct rev_info *revs, revs->max_count != -1 || revs->min_age != -1 || revs->max_age != -1) usage(builtin_diff_usage); + if (read_cache() < 0) { + perror("read_cache"); + return -1; + } return run_diff_index(revs, cached); } |