Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
builtin/remote.c: rearrange xcalloc arguments
[gitweb.git]
/
grep.c
diff --git
a/grep.c
b/grep.c
index 94f7290eb764119bfdca8d0497730f082731a24e..4aef0a69d084deee61486e43bc62ae2da6b6b440 100644
(file)
--- a/
grep.c
+++ b/
grep.c
@@
-1653,7
+1653,7
@@
void grep_source_init(struct grep_source *gs, enum grep_source_type type,
break;
case GREP_SOURCE_SHA1:
gs->identifier = xmalloc(20);
-
memcpy(gs->identifier, identifier, 20
);
+
hashcpy(gs->identifier, identifier
);
break;
case GREP_SOURCE_BUF:
gs->identifier = NULL;