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

Re: [PATCH v2] fast-import: tag may point to any object type

From
Shawn O. Pearce <spearce@spearce.org>
Date
Jan 13, 2010, 17:24 UTC
Message-ID
<20100113172456.GB18625@spearce.org>
In-Reply-To
<20100113123532.GC10586@dpotapov.dyndns.org>
Dmitry Potapov <dpotapov@gmail.com> wrote:
> If you tried to export the official git repository, and then to import it
> back then git-fast-import would die complaining that "Mark :1 not a commit".
...
Show 13 quoted lines
> diff --git a/fast-import.c b/fast-import.c
> index cd87049..4fdf809 100644
> --- a/fast-import.c
> +++ b/fast-import.c
> @@ -2325,19 +2326,20 @@ static void parse_new_tag(void)
>  	} else if (!get_sha1(from, sha1)) {
>  		unsigned long size;
>  		char *buf;
>  
> +		type = sha1_object_info(sha1, NULL);
>  		buf = read_object_with_reference(sha1,
> -			commit_type, &size, sha1);
> +			typename(type), &size, sha1);
This is better spelled as:
  buf = read_sha1_file(sha1, &type, &size);
But otherwise the patch looks correct now, thanks.
If you could make this one change, add my
  Acked-by: Shawn O. Pearce <spearce@spearce.org>
and resend so Junio can apply, thanks.
-- 
Shawn.
Previous: Dmitry PotapovNext: Dmitry Potapov
Message 4 of 5 in “fast-import: tag may point to any object type”
  1. fast-import: tag may point to any object typeDmitry Potapov, Jan 11, 2010
  2. Shawn O. PearceJan 11, 2010
  3. fast-import: tag may point to any object typeDmitry Potapov, Jan 13, 2010
  4. Shawn O. PearceJan 13, 2010
  5. fast-import: tag may point to any object typeDmitry Potapov, Jan 14, 2010

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.