append_one_rev(): rewrite to work with object_id
authorMichael Haggerty <redacted>
Mon, 25 May 2015 18:38:47 +0000 (18:38 +0000)
committerJunio C Hamano <redacted>
Mon, 25 May 2015 19:19:31 +0000 (12:19 -0700)
Signed-off-by: Michael Haggerty <redacted>
Signed-off-by: brian m. carlson <redacted>
Signed-off-by: Junio C Hamano <redacted>
builtin/show-branch.c

index 7e006577e26752d3741ebd97ea6d3722e6b8db9f..b861e4192601f59a4537a1aa7e40b6398afa53f2 100644 (file)
@@ -536,9 +536,9 @@ static int show_independent(struct commit **rev,
 
 static void append_one_rev(const char *av)
 {
-       unsigned char revkey[20];
-       if (!get_sha1(av, revkey)) {
-               append_ref(av, revkey, 0);
+       struct object_id revkey;
+       if (!get_sha1(av, revkey.hash)) {
+               append_ref(av, revkey.hash, 0);
                return;
        }
        if (strchr(av, '*') || strchr(av, '?') || strchr(av, '[')) {
git clone https://git.99rst.org/PROJECT