summaryrefslogtreecommitdiff
path: root/ref-filter.c
diff options
context:
space:
mode:
authorbrian m. carlson <sandals@crustytoothpaste.net>2015-11-10 02:22:29 (GMT)
committerJeff King <peff@peff.net>2015-11-20 13:02:05 (GMT)
commited1c9977cb1b63e4270ad8bdf967a2d02580aa08 (patch)
treef5b52ccae09103672c62c1c11ff0bddc78199829 /ref-filter.c
parentf2fd0760f62e79609fef7bfd7ecebb002e8e4ced (diff)
downloadgit-ed1c9977cb1b63e4270ad8bdf967a2d02580aa08.zip
git-ed1c9977cb1b63e4270ad8bdf967a2d02580aa08.tar.gz
git-ed1c9977cb1b63e4270ad8bdf967a2d02580aa08.tar.bz2
Remove get_object_hash.
Convert all instances of get_object_hash to use an appropriate reference to the hash member of the oid member of struct object. This provides no functional change, as it is essentially a macro substitution. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Jeff King <peff@peff.net>
Diffstat (limited to 'ref-filter.c')
-rw-r--r--ref-filter.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ref-filter.c b/ref-filter.c
index 2850c31..7bef7f8 100644
--- a/ref-filter.c
+++ b/ref-filter.c
@@ -372,7 +372,7 @@ static void grab_common_values(struct atom_value *val, int deref, struct object
v->s = xstrfmt("%lu", sz);
}
else if (deref)
- grab_objectname(name, get_object_hash(*obj), v);
+ grab_objectname(name, obj->oid.hash, v);
}
}
@@ -992,7 +992,7 @@ static void populate_value(struct ref_array_item *ref)
* If it is a tag object, see if we use a value that derefs
* the object, and if we do grab the object it refers to.
*/
- tagged = get_object_hash(*((struct tag *)obj)->tagged);
+ tagged = ((struct tag *)obj)->tagged->oid.hash;
/*
* NEEDSWORK: This derefs tag only once, which
@@ -1218,7 +1218,7 @@ static const unsigned char *match_points_at(struct sha1_array *points_at,
if (!obj)
die(_("malformed object at '%s'"), refname);
if (obj->type == OBJ_TAG)
- tagged_sha1 = get_object_hash(*((struct tag *)obj)->tagged);
+ tagged_sha1 = ((struct tag *)obj)->tagged->oid.hash;
if (tagged_sha1 && sha1_array_lookup(points_at, tagged_sha1) >= 0)
return tagged_sha1;
return NULL;