Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reference: Fix panic when trying to shorten origin address #158

Merged
merged 1 commit into from
Nov 15, 2022

Conversation

radeksimko
Copy link
Member

As the in-line comment explains, previously we'd try to "shorten" the origin address by actually "growing" it.

In theory this could have happened prior to #150 but it apparently never did, or nobody reported it. It would require an origin with less segments than the compared target. In most (all?) cases, the targets have at least 2 segments and so that would require comparison with a single-segment origin, such as foo. This was also additionally gated by another condition, which was somewhat naively modified to account for local addresses and that condition is no longer necessary now.

@radeksimko radeksimko added the bug Something isn't working label Nov 15, 2022
@radeksimko radeksimko requested a review from a team November 15, 2022 15:33
Copy link
Member

@dbanck dbanck left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@radeksimko radeksimko merged commit fe484f8 into main Nov 15, 2022
@radeksimko radeksimko deleted the b-fix-slice-access-panic branch November 15, 2022 17:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants