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

[PATCH] import-tars: be nice to wrong directory modes

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Apr 28, 2007, 23:59 UTC
Message-ID
<Pine.LNX.4.64.0704290159230.29859@racer.site>

Some tars seem to have modes 0755 for directories, not 01000755. Do not generate an empty object for them, but ignore them.

Noticed by riddochc on IRC.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
 contrib/fast-import/import-tars.perl |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/contrib/fast-import/import-tars.perl b/contrib/fast-import/import-tars.perl
index 1842146..5575080 100755
--- a/contrib/fast-import/import-tars.perl
+++ b/contrib/fast-import/import-tars.perl
@@ -52,6 +52,7 @@ foreach my $tar_file (@ARGV)
 			Z8 Z1 Z100 Z6
 			Z2 Z32 Z32 Z8 Z8 Z*', $_;
 		last unless $name;
+		next if $name =~ '/$';
 		$mode = oct $mode;
 		$size = oct $size;
 		$mtime = oct $mtime;
-- 
1.5.2.rc0.2496.g74f7
Next: Shawn O. Pearce
Message 1 of 5 in “import-tars: be nice to wrong directory modes”
  1. import-tars: be nice to wrong directory modesJohannes Schindelin, Apr 28, 2007
  2. Shawn O. PearceApr 29, 2007
  3. Junio C HamanoApr 29, 2007
  4. Shawn O. PearceApr 29, 2007
  5. Randal L. SchwartzApr 29, 2007

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.