clean up and optimize nth_packed_object_sha1() usage
commitd72308e01c5977177cda0aed06cfeee9192e1247
authorNicolas Pitre <nico@cam.org>
Wed, 4 Apr 2007 20:49:04 +0000 (4 16:49 -0400)
committerJunio C Hamano <junkio@cox.net>
Thu, 5 Apr 2007 21:59:47 +0000 (5 14:59 -0700)
treec42895d515c9bdae4d429ddd93c74b2f082fe09d
parentd5ad36fe3584551a09160edce3e76d559d412ae5
clean up and optimize nth_packed_object_sha1() usage

Let's avoid the open coded pack index reference in pack-object and use
nth_packed_object_sha1() instead.  This will help encapsulating index
format differences in one place.

And while at it there is no reason to copy SHA1's over and over while a
direct pointer to it in the index will do just fine.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Acked-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-fsck.c
builtin-pack-objects.c
cache.h
pack-check.c
sha1_file.c
sha1_name.c