Skip to content

Conversation

vapier
Copy link
Contributor

@vapier vapier commented Jan 16, 2025

Git does not limit relative paths in alternates to the first repository, so libgit2 shouldn't either.

Git does not limit relative paths in alternates to the first
repository, so libgit2 shouldn't either.
@vapier
Copy link
Contributor Author

vapier commented Jan 16, 2025

The code has behaved this way since it was originally merged in 85e7efa1630855c5c8bd9893f732494bda51b591 in PR #719. I can't see an explanation as to why the code decided to only load relative links for the current repo in either place. Maybe git itself used to behave this way, but current versions definitely do not.

FWIW we hit this in CrOS with details in https://issuetracker.google.com/214563046, although it's not terribly interesting tbh.

@ethomson
Copy link
Member

Indeed; I'm not sure either, but it looks like your analysis is correct. Thanks!

@ethomson ethomson merged commit 3eadce3 into libgit2:main Jan 21, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants