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

Re: Troubles when directory is replaced by symlink

From
Johannes Sixt <j.sixt@viscovery.net>
Date
Jun 26, 2009, 14:14 UTC
Message-ID
<4A44D7C2.1060706@viscovery.net>
In-Reply-To
<868wjf9lxq.fsf@broadpark.no>
Kjetil Barvik schrieb:
Show 6 quoted lines
> Subject: [PATCH] lstat_cache: guard against full match of length of 'name' parameter
> 
> longest_path_match() in symlinks.c does exactly what it's name says,
> but in some cases that match can be too long, since the
> has_*_leading_path() functions assumes that the match will newer be as
> long as the name string given to the function.

And these "some cases" are? When "a directory was replaced by a symlink" ("or what??" I am inclined to add). Would you please be very specific here, perhaps with an example, so that we still know the details in 6 months.

> +test_expect_success 'checkout of master - alpha/file and beta/alpha/file should exist' '
test_expect_success 'checkout replaces symlink by directory' '

BTW, this is what the test seems to check, and it is the opposite of what the mail's Subject says. So, which one is it?

> +
> +	git checkout master &&
> +	ls alpha/file beta/alpha/file
	git checkout master &&
	! test -h alpha &&
	test -f alpha/file &&
	test -f beta/alpha/file
-- Hannes
Previous: Kjetil Barvik
Message 9 of 9 in “Troubles when directory is replaced by symlink”
  1. Alexander GladyshJun 5, 2009
  2. Alexander GladyshJun 9, 2009
  3. Jeff KingJun 11, 2009
  4. Kjetil BarvikJun 11, 2009
  5. Kjetil BarvikJun 14, 2009
  6. James PickensJun 24, 2009
  7. Kjetil BarvikJun 25, 2009
  8. Kjetil BarvikJun 26, 2009
  9. Johannes SixtJun 26, 2009

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.