From 7922a17d4da969c70d9382206244b6be0a7a3475 Mon Sep 17 00:00:00 2001 From: Philippe Blain Date: Mon, 13 Jun 2022 12:29:41 +0000 Subject: [PATCH] diff-format.txt: dst can be 0* SHA-1 when path is deleted, too "dst" can legitimately be "0\{40\}" for a creation patch, e.g. when the stat information is stale, but it falls into "look at work tree" case. The original description in b6d8f309 ([PATCH] diff-raw format update take #2., 2005-05-23) forgot that deletion also makes the "dst" 0* SHA-1. Signed-off-by: Philippe Blain Signed-off-by: Junio C Hamano --- Documentation/diff-format.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/diff-format.txt b/Documentation/diff-format.txt index 7a9c3b6ff4c6a2..b8319eeb41da3f 100644 --- a/Documentation/diff-format.txt +++ b/Documentation/diff-format.txt @@ -43,7 +43,7 @@ That is, from the left to the right: . a space. . sha1 for "src"; 0\{40\} if creation or unmerged. . a space. -. sha1 for "dst"; 0\{40\} if creation, unmerged or "look at work tree". +. sha1 for "dst"; 0\{40\} if deletion, unmerged or "look at work tree". . a space. . status, followed by optional "score" number. . a tab or a NUL when `-z` option is used.