[PATCH 04/17] fixup! pack-objects: recognize v4 as pack source

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx>
---
 builtin/pack-objects.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c
index 30559e8..8e2e5e9 100644
--- a/builtin/pack-objects.c
+++ b/builtin/pack-objects.c
@@ -1436,7 +1436,7 @@ static void check_object(struct object_entry *entry)
 				const unsigned char *sha1, *cp;
 				cp = buf + used;
 				sha1 = get_sha1ref(p, &cp);
-				entry->in_pack_header_size = cp - buf;;
+				entry->in_pack_header_size = cp - buf;
 				if (reuse_delta && !entry->preferred_base)
 					base_ref = sha1;
 				break;
@@ -1490,6 +1490,9 @@ static void check_object(struct object_entry *entry)
 			 * never consider reused delta as the base object to
 			 * deltify other objects against, in order to avoid
 			 * circular deltas.
+			 *
+			 * OBJ_TREE is kept in entry->type in v4 so we
+			 * know to when to write OBJ_PV4_TREE.
 			 */
 			if (pack_version < 4 || entry->type != OBJ_TREE)
 				entry->type = entry->in_pack_type;
-- 
1.8.2.83.gc99314b

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]