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

NIO needs a way to handle spaces in filenames #1139

Open
yfarjoun opened this issue Jun 4, 2018 · 1 comment
Open

NIO needs a way to handle spaces in filenames #1139

yfarjoun opened this issue Jun 4, 2018 · 1 comment

Comments

@yfarjoun
Copy link
Contributor

yfarjoun commented Jun 4, 2018

Right now much of the processing of files goes through getAbsolutePath().toUri().toString() which breaks at the toUri() step when there's a space in the file.

Specifically you get a %20 in the filename instead of a space.

@jb-adams
Copy link
Contributor

This issue looks related to #1034.

To avoid introducing URL encoding into a local filesystem path, can we first check that the path is a valid URI? If so, we can convert it via the current method toUri().toString(), if not, we treat it as a local path and only use .toString(). A single method could perform the check and output the correct string based on the input path.

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

No branches or pull requests

2 participants