Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
grep: take the read-lock when adding a submodule
[gitweb.git]
/
builtin
/
grep.c
diff --git
a/builtin/grep.c
b/builtin/grep.c
index cd0e51f3c04b1e6fc297a8806fa663d86ebc7734..6946cf4bbc825cbd1335ab5464428f54483701f8 100644
(file)
--- a/
builtin/grep.c
+++ b/
builtin/grep.c
@@
-431,7
+431,9
@@
static int grep_submodule(struct grep_opt *opt, struct repository *superproject,
* store is no longer global and instead is a member of the repository
* object.
*/
+ grep_read_lock();
add_to_alternates_memory(submodule.objectdir);
+ grep_read_unlock();
if (oid) {
struct object *object;