Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
rec: Prevent an infinite loop if we need auth and the best match is not #5549
The current code gets the most specific entry, and checks whether it's still valid. If it's not, it removes it from the index and loops to fetch the next best match. However, if the entry is valid but doesn't hold authoritative data and the caller requested it, it tries to loop to get a new match. Since the entry is still present in the index, it will just get the same entry over and over, triggering an infinite loop.