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

agent: use filepath.Join to construct portfile path #140

Merged
merged 1 commit into from
Mar 9, 2021

Conversation

tklauser
Copy link
Collaborator

@tklauser tklauser commented Mar 9, 2021

If gopsdir contains a trailing slash, the resulting portfile path will
contain a trailing double slash which might lead to problems in some
circumstances. Moreover iut could also be problematic on platforms where
other path separators are used (e.g. Windows).

Fix this by using filepath.Join to construct the path.

If gopsdir contains a trailing slash, the resulting portfile path will
contain a trailing double slash which might lead to problems in some
circumstances. Moreover iut could also be problematic on platforms where
other path separators are used (e.g. Windows).

Fix this by using filepath.Join to construct the path.
@tklauser tklauser requested review from rakyll and odeke-em March 9, 2021 10:26
Copy link
Collaborator

@odeke-em odeke-em left a comment

Choose a reason for hiding this comment

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

Good catch @tklauser, let’s also comb through for more of such unportable path constructions. LGTM, and thank you!

@tklauser
Copy link
Collaborator Author

tklauser commented Mar 9, 2021

Good catch @tklauser, let’s also comb through for more of such unportable path constructions. LGTM, and thank you!

Thanks for the review @odeke-em. Some quick greping didn't show any other obvious instances of these.

@odeke-em
Copy link
Collaborator

odeke-em commented Mar 9, 2021 via email

@tklauser tklauser merged commit 55729d4 into master Mar 9, 2021
@tklauser tklauser deleted the portfile-path-join branch March 9, 2021 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants