diff options
author | Junio C Hamano <gitster@pobox.com> | 2008-11-27 19:24:13 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2008-11-27 19:24:13 -0800 |
commit | 2af9664776a237baa7ce67789bc5d2b54a36d95c (patch) | |
tree | 7175a6e86b9f6dc1448dd2527d66f64a2e30c3ab /builtin-commit.c | |
parent | 98cdf78c5cf1356757ccc4d25c212ae1f38339e4 (diff) | |
parent | 7c4ea599b0d44e46c4f96bf955b62d96126b53ff (diff) | |
download | git-2af9664776a237baa7ce67789bc5d2b54a36d95c.tar.gz |
Merge branch 'lt/preload-lstat'
* lt/preload-lstat:
Fix index preloading for racy dirty case
Add cache preload facility
Diffstat (limited to 'builtin-commit.c')
-rw-r--r-- | builtin-commit.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/builtin-commit.c b/builtin-commit.c index 591d16b91e..1677e6b45f 100644 --- a/builtin-commit.c +++ b/builtin-commit.c @@ -225,18 +225,18 @@ static char *prepare_index(int argc, const char **argv, const char *prefix) if (interactive) { interactive_add(argc, argv, prefix); - if (read_cache() < 0) + if (read_cache_preload(NULL) < 0) die("index file corrupt"); commit_style = COMMIT_AS_IS; return get_index_file(); } - if (read_cache() < 0) - die("index file corrupt"); - if (*argv) pathspec = get_pathspec(prefix, argv); + if (read_cache_preload(pathspec) < 0) + die("index file corrupt"); + /* * Non partial, non as-is commit. * |