Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
show_ref(): convert local variable peeled to object_id
author
Michael Haggerty
<mhagger@alum.mit.edu>
Mon, 25 May 2015 18:38:52 +0000
(18:38 +0000)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 25 May 2015 19:19:32 +0000
(12:19 -0700)
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/show-ref.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
f0a011f
)
diff --git
a/builtin/show-ref.c
b/builtin/show-ref.c
index 18f84fbc53883ceb30564b44e604361857aa9f33..dfbc314ac27aae11a660e04d821816325c040e67 100644
(file)
--- a/
builtin/show-ref.c
+++ b/
builtin/show-ref.c
@@
-30,7
+30,7
@@
static int show_ref(const char *refname, const struct object_id *oid,
int flag, void *cbdata)
{
const char *hex;
-
unsigned char peeled[20]
;
+
struct object_id peeled
;
if (show_head && !strcmp(refname, "HEAD"))
goto match;
@@
-82,8
+82,8
@@
static int show_ref(const char *refname, const struct object_id *oid,
if (!deref_tags)
return 0;
- if (!peel_ref(refname, peeled)) {
- hex = find_unique_abbrev(peeled, abbrev);
+ if (!peel_ref(refname, peeled
.hash
)) {
+ hex = find_unique_abbrev(peeled
.hash
, abbrev);
printf("%s %s^{}\n", hex, refname);
}
return 0;