git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 1/2] git-archive --format=zip: use default version ID

From
Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Date
Oct 6, 2006, 23:47 UTC
Message-ID
<4526EB0C.6000802@lsrfire.ath.cx>

Use 10 for the "version needed to extract" field. This is the default value, and we want to use it because we don't do anything special. Info-ZIP's zip uses it, too.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
---
 archive-zip.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/archive-zip.c b/archive-zip.c
index 3ffdad6..ae74623 100644
--- a/archive-zip.c
+++ b/archive-zip.c
@@ -214,7 +214,7 @@ static int write_zip_entry(const unsigne
 
 	copy_le32(dirent.magic, 0x02014b50);
 	copy_le16(dirent.creator_version, 0);
-	copy_le16(dirent.version, 20);
+	copy_le16(dirent.version, 10);
 	copy_le16(dirent.flags, 0);
 	copy_le16(dirent.compression_method, method);
 	copy_le16(dirent.mtime, zip_time);
@@ -236,7 +236,7 @@ static int write_zip_entry(const unsigne
 	zip_dir_entries++;
 
 	copy_le32(header.magic, 0x04034b50);
-	copy_le16(header.version, 20);
+	copy_le16(header.version, 10);
 	copy_le16(header.flags, 0);
 	copy_le16(header.compression_method, method);
 	copy_le16(header.mtime, zip_time);
-- 
1.4.2.3.gf59615
Message 1 of 1 in “git-archive --format=zip: use default version ID”
  1. 1/2 git-archive --format=zip: use default version IDRene Scharfe, Oct 6, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.