X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=mktag.c;h=a3b4270c18ea78fa36f7243de5a9e05e2066e030;hb=752c0c24926aacbceca0d27de6ad22cbb7dd0709;hp=a609e3ebd106ed985fa2065dc4af6565e5a379a6;hpb=14468ab45bae83ad300f17f41fe8fd555329ee5e;p=git.git diff --git a/mktag.c b/mktag.c index a609e3ebd..a3b4270c1 100644 --- a/mktag.c +++ b/mktag.c @@ -19,16 +19,17 @@ /* * We refuse to tag something we can't verify. Just because. */ -static int verify_object(unsigned char *sha1, const char *expected_type) +static int verify_object(const unsigned char *sha1, const char *expected_type) { int ret = -1; enum object_type type; unsigned long size; - void *buffer = read_sha1_file(sha1, &type, &size); + const unsigned char *repl; + void *buffer = read_sha1_file_repl(sha1, &type, &size, &repl); if (buffer) { if (type == type_from_string(expected_type)) - ret = check_sha1_signature(sha1, buffer, size, expected_type); + ret = check_sha1_signature(repl, buffer, size, expected_type); free(buffer); } return ret;