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

Re: [PATCH] git-apply: apply submodule changes

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Aug 10, 2007, 12:39 UTC
Message-ID
<Pine.LNX.4.64.0708101337510.21857@racer.site>
In-Reply-To
<20070810093049.GA868MdfPADPa@greensroom.kotnet.org>
Hi,
On Fri, 10 Aug 2007, Sven Verdoolaege wrote:
Show 11 quoted lines
> @@ -2387,7 +2405,9 @@ static void add_index_file(const char *path, unsigned mode, void *buf, unsigned
>  			die("unable to stat newly created file %s", path);
>  		fill_stat_cache_info(ce, &st);
>  	}
> -	if (write_sha1_file(buf, size, blob_type, ce->sha1) < 0)
> +	if (S_ISGITLINK(mode))
> +		get_sha1_hex(buf + strlen("Subproject commit "), ce->sha1);
> +	else if (write_sha1_file(buf, size, blob_type, ce->sha1) < 0)
>  		die("unable to create backing store for newly created file %s", path);
>  	if (add_cache_entry(ce, ADD_CACHE_OK_TO_ADD) < 0)
>  		die("unable to add cache entry for %s", path);
I guess that you need to catch an error from get_sha1_hex(), too.

I hope it is not to much to ask for a patch to t7400 to show what this patch fixes?

Ciao, Dscho

Previous: Johannes SchindelinNext: Sven Verdoolaege
Message 3 of 19 in “git-apply: apply submodule changes”
  1. git-apply: apply submodule changesSven Verdoolaege, Aug 10, 2007
  2. Johannes SchindelinAug 10, 2007
  3. Johannes SchindelinAug 10, 2007
  4. git-apply: apply submodule changesSven Verdoolaege, Aug 10, 2007
  5. Junio C HamanoAug 11, 2007
  6. Sven VerdoolaegeAug 11, 2007
  7. Junio C HamanoAug 11, 2007
  8. git-apply: apply submodule changesSven Verdoolaege, Aug 12, 2007
  9. Junio C HamanoAug 12, 2007
  10. Sven VerdoolaegeAug 12, 2007
  11. Junio C HamanoAug 12, 2007
  12. Sven VerdoolaegeAug 13, 2007
  13. git-apply: apply submodule changesSven Verdoolaege, Aug 13, 2007
  14. Junio C HamanoAug 13, 2007
  15. Junio C HamanoAug 14, 2007
  16. Sven VerdoolaegeAug 14, 2007
  17. Junio C HamanoAug 14, 2007
  18. git-apply: apply submodule changesSven Verdoolaege, Aug 15, 2007
  19. Junio C HamanoAug 16, 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.