From: "Martin Ågren" <martin.agren@gmail.com>
To: Ross Light <ross@zombiezen.com>
Cc: git@vger.kernel.org
Subject: [PATCH 2/2] pack-format.txt: document lengths at start of delta data
Date: Mon, 21 Dec 2020 08:54:59 +0100 [thread overview]
Message-ID: <c515a44179576db202c8b6d2419459df0e67ec0a.1608537234.git.martin.agren@gmail.com> (raw)
In-Reply-To: <cover.1608537234.git.martin.agren@gmail.com>
We document the delta data as a set of instructions, but forget to
document the two lengths that precede those instructions: the length of
the base object and the length of the object to be reconstructed. Fix
this omission.
Reported-by: Ross Light <ross@zombiezen.com>
Signed-off-by: Martin Ågren <martin.agren@gmail.com>
---
Documentation/technical/pack-format.txt | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/Documentation/technical/pack-format.txt b/Documentation/technical/pack-format.txt
index 42198de74c..05889a2e43 100644
--- a/Documentation/technical/pack-format.txt
+++ b/Documentation/technical/pack-format.txt
@@ -82,7 +82,10 @@ Ref-delta can also refer to an object outside the pack (i.e. the
so-called "thin pack"). When stored on disk however, the pack should
be self contained to avoid cyclic dependency.
-The delta data is a sequence of instructions to reconstruct an object
+The delta data starts with the length of the base object and the
+length of the object to be reconstructed. These lengths are
+encoded as varints. The remainder of
+the delta data is a sequence of instructions to reconstruct the object
from the base object. If the base object is deltified, it must be
converted to canonical form first. Each instruction appends more and
more data to the target object until it's complete. There are two
--
2.30.0.rc1
next prev parent reply other threads:[~2020-12-21 7:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-19 17:07 Documentation errors for HTTP protocol v2 and packfile Ross Light
2020-12-21 7:54 ` [PATCH 0/2] pack-format.txt: document lengths at start of delta data Martin Ågren
2020-12-21 7:54 ` [PATCH 1/2] pack-format.txt: define "varint" format Martin Ågren
2020-12-21 21:40 ` Junio C Hamano
2020-12-29 22:41 ` Martin Ågren
2020-12-21 7:54 ` Martin Ågren [this message]
2020-12-23 4:40 ` [PATCH 0/2] pack-format.txt: document lengths at start of delta data Ross Light
2020-12-29 22:43 ` [PATCH v2] pack-format.txt: document sizes " Martin Ågren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c515a44179576db202c8b6d2419459df0e67ec0a.1608537234.git.martin.agren@gmail.com \
--to=martin.agren@gmail.com \
--cc=git@vger.kernel.org \
--cc=ross@zombiezen.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).