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

fix: correctly parse default_app path on windows #18086

Merged
merged 1 commit into from
May 1, 2019

Conversation

MarshallOfSound
Copy link
Member

Noticed this on my Windows machine while verifying the 6.0.0-beta.1 release. On windows, pathname looks like /c:/a/b/c (that preceding / breaks things). No notes as it's a default_app UI change, app devs don't need to know.

This is the bug -->
image

Notes: no-notes

@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label May 1, 2019
Copy link
Contributor

@miniak miniak left a comment

Choose a reason for hiding this comment

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

what about doing a similar check to how we enforce preload scripts to be from the appPath?
https://github.com/electron/electron/blob/master/lib/browser/rpc-server.js#L514

@miniak
Copy link
Contributor

miniak commented May 1, 2019

@MarshallOfSound maybe related to #18092

@MarshallOfSound
Copy link
Member Author

@miniak The issue here isn't asar or realpath. We can't call realpath on the result of URL().pathname as URL does not return a valid Windows path. It is very much UNIX style.

@MarshallOfSound MarshallOfSound merged commit 913bd4c into master May 1, 2019
@release-clerk
Copy link

release-clerk bot commented May 1, 2019

No Release Notes

@MarshallOfSound MarshallOfSound deleted the fix-def-app-win branch May 1, 2019 20:00
@trop
Copy link
Contributor

trop bot commented May 1, 2019

I have automatically backported this PR to "6-0-x", please check out #18102

kiku-jw pushed a commit to kiku-jw/electron that referenced this pull request May 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new-pr 🌱 PR opened in the last 24 hours
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants