git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris Wright <chrisw@osdl.org>
To: Petr Baudis <pasky@suse.cz>
Cc: Russell King <rmk@arm.linux.org.uk>, git@vger.kernel.org
Subject: Re: [ANNOUNCE] Cogito-0.12
Date: Mon, 11 Jul 2005 13:30:42 -0700	[thread overview]
Message-ID: <20050711203042.GR5324@shell0.pdx.osdl.net> (raw)
In-Reply-To: <20050710145954.GB24249@pasky.ji.cz>

* Petr Baudis (pasky@suse.cz) wrote:
> Ok, cg-pull didn't quite handle this. I've fixed it so that it should
> reasonably handle it now. Hopefully.

Is this plus the zero-sized fix worth making cogito-0.12-2 rpm release?

IOW, these two patches...

diff-tree 291ec0f2d2ce65e5ccb876b46d6468af49ddb82e (from 72347a233e6f3c176059a28f0817de6654ef29c7)
tree a1d3a4e01516f1d924c407a9e42a6df0d13b43b6
parent 72347a233e6f3c176059a28f0817de6654ef29c7
author Linus Torvalds <torvalds@g5.osdl.org> 1120608369 -0700
committer Linus Torvalds <torvalds@g5.osdl.org> 1120608369 -0700

    Don't special-case a zero-sized compression.
    
    zlib actually writes a header for that case, and while ignoring that
    header will get us the right data, it will also end up messing up our
    stream position.  So we actually want zlib to "uncompress" even an empty
    object.

diff --git a/unpack-objects.c b/unpack-objects.c
--- a/unpack-objects.c
+++ b/unpack-objects.c
@@ -55,8 +55,6 @@ static void *get_data(unsigned long size
 	z_stream stream;
 	void *buf = xmalloc(size);
 
-	if (!size)
-		return buf;
 	memset(&stream, 0, sizeof(stream));
 
 	stream.next_out = buf;
diff-tree 7b754d7f0800117cd97afa5e806e50c7fd16d8c1 (from a2503fd85e6bb7f25d134a5634a1d8efc93fee5f)
Author: Petr Baudis <pasky@suse.cz>
Date:   Sun Jul 10 16:59:28 2005 +0200

    Fix cg-pull to handle packed tags properly
    
    If the objects referenced by refs/tags/ are packed, it wouldn't detect
    them properly and instead try to refetch them, but they are likely to
    be packed on the other side as well and that makes them impossible to
    be fetched explicitly (which isn't a problem as long as they are the
    same branch).
    
    Also, the fetch failure message was confusing.
    
    Reported by Russel King.

diff --git a/cg-pull b/cg-pull
--- a/cg-pull
+++ b/cg-pull
@@ -294,13 +294,14 @@ $fetch -i -s -u -d "$uri/refs/tags" "$_g
 	for tag in *; do
 		[ "$tag" = "*" ] && break
 		tagid=$(cat $tag)
-		tagfile=objects/${tagid:0:2}/${tagid:2}
-		[ -s "../../$tagfile" ] && continue
+		GIT_DIR=../../../$_git git-cat-file -t "$tagid" >/dev/null 2>&1 && continue
 		echo -n "Missing object of tag $tag... "
+		# In case it's not in a packfile...
+		tagfile=objects/${tagid:0:2}/${tagid:2}
 		if $fetch -i -s "$uri/$tagfile" "../../$tagfile" 2>/dev/null >&2; then
 			echo "retrieved"
 		else
-			echo "different source (obsolete tag?)"
+			echo "unable to retrieve"
 		fi
 	done
 )

  reply	other threads:[~2005-07-11 20:33 UTC|newest]

Thread overview: 66+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-03 23:46 [ANNOUNCE] Cogito-0.12 Petr Baudis
2005-07-06 12:01 ` Brian Gerst
2005-07-07 14:45   ` Petr Baudis
2005-07-07 17:21     ` Junio C Hamano
2005-07-07 19:04       ` Linus Torvalds
2005-07-07 19:57         ` Junio C Hamano
2005-07-07 21:58           ` Linus Torvalds
2005-07-07 22:10             ` Junio C Hamano
2005-07-07 20:00         ` Junio C Hamano
2005-07-07 21:29         ` Eric W. Biederman
2005-07-07 22:23           ` Linus Torvalds
2005-07-08  2:11             ` Eric W. Biederman
2005-07-08  1:54           ` Dumb servers (was: [ANNOUNCE] Cogito-0.12) Kevin Smith
2005-07-08  2:27             ` Linus Torvalds
2005-07-07 22:14         ` [ANNOUNCE] Cogito-0.12 Petr Baudis
2005-07-07 22:52           ` Linus Torvalds
2005-07-07 23:16             ` [PATCH] Pull efficiently from a dumb git store Junio C Hamano
2005-07-07 23:50               ` [PATCH] rev-list: add "--objects=self-sufficient" flag Junio C Hamano
2005-07-07 23:58                 ` Linus Torvalds
2005-07-08  1:02                   ` [PATCH] rev-list: add "--full-objects" flag Junio C Hamano
2005-07-08  1:33                     ` Linus Torvalds
2005-07-08  1:46                     ` Linus Torvalds
2005-07-08  2:17                       ` Junio C Hamano
2005-07-08  2:39                         ` Linus Torvalds
2005-07-09 21:09                           ` Eric W. Biederman
2005-07-10  5:11                             ` Linus Torvalds
2005-07-10  6:28                               ` Junio C Hamano
2005-07-10 21:48                             ` Sven Verdoolaege
2005-07-10 22:36                             ` Linus Torvalds
2005-07-11 15:19                               ` Eric W. Biederman
2005-07-11 16:38                                 ` Linus Torvalds
2005-07-12  0:44                                   ` Eric W. Biederman
2005-07-12  1:14                                     ` Linus Torvalds
2005-07-12  2:38                                       ` Eric W. Biederman
2005-07-12  3:21                                         ` Linus Torvalds
2005-07-12  3:39                                           ` Eric W. Biederman
2005-07-12  4:48                                             ` Linus Torvalds
2005-07-11 17:53                                 ` Linus Torvalds
     [not found]                           ` <7vy88gzn6s.fsf@assigned-by-dhcp.cox.net>
     [not found]                             ` <Pine.LNX.4.58.0507082109140.17536@g5.osdl.org>
     [not found]                               ` <7vfyumj8hn.fsf_-_@assigned-by-dhcp.cox.net>
2005-07-11  7:00                                 ` [PATCH] Check packs and then files Junio C Hamano
2005-07-08  1:03                   ` [PATCH] Give --full-objects flag to rev-list when preparing a dumb server Junio C Hamano
2005-07-07 23:50               ` [PATCH] Use --objects=self-sufficient flag to rev-list Junio C Hamano
2005-07-07 23:52             ` [ANNOUNCE] Cogito-0.12 Tony Luck
2005-07-07 23:54               ` Junio C Hamano
2005-07-07 23:59               ` Linus Torvalds
2005-07-08  0:09                 ` Tony Luck
2005-07-08  0:23                   ` Linus Torvalds
2005-07-09 21:58                     ` Russell King
2005-07-09 22:29                       ` Russell King
2005-07-09 23:46                         ` Junio C Hamano
2005-07-10  5:02                           ` Linus Torvalds
2005-07-10  5:15                             ` Linus Torvalds
2005-07-10  6:55                               ` Russell King
2005-07-10  7:15                                 ` Junio C Hamano
2005-07-10 12:46                                   ` Russell King
2005-07-10 16:51                                     ` Linus Torvalds
2005-07-10 19:15                                       ` Russell King
2005-07-10 20:03                                         ` Linus Torvalds
2005-07-10 20:32                                           ` Russell King
2005-07-10 21:40                                             ` Linus Torvalds
2005-07-10  8:09                       ` Russell King
2005-07-10 14:59                         ` Petr Baudis
2005-07-11 20:30                           ` Chris Wright [this message]
2005-07-08  0:09                 ` Linus Torvalds
2005-07-08  8:14                   ` Petr Baudis
2005-07-08 15:56                     ` Daniel Barkalow
2005-07-07  6:22 ` Chris Wright

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=20050711203042.GR5324@shell0.pdx.osdl.net \
    --to=chrisw@osdl.org \
    --cc=git@vger.kernel.org \
    --cc=pasky@suse.cz \
    --cc=rmk@arm.linux.org.uk \
    /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).