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

Fat-JAR-Error: on unpackFromJarURL with whitespaces in the path of windows filepath #1258

Closed
nixoso opened this issue Dec 29, 2015 · 0 comments

Comments

@nixoso
Copy link

nixoso commented Dec 29, 2015

This happens in Vert.x 3.2.

On start-up a vertx-web-fat-JAR on a path with whitespace i get a internall server error.

Example -> ok:
Working dir: C:\Users*Max*\git\Project\target
Start-CMD: java -jar webapp.jar

Example -> failed:
Working dir: C:\Users*Max Mustermann*\git\Project\target
Start-CMD: java -jar webapp.jar

500 C:\Users\Max%20Mustermann\git\Project\target\webapp.jar (Das System kann den angegebenen Pfad nicht finden)

    java.io.FileInputStream.open0(Native Method)
    java.io.FileInputStream.open(Unknown Source)
    java.io.FileInputStream.(Unknown Source)
    java.io.FileInputStream.(Unknown Source)
    io.vertx.core.impl.FileResolver.toZipInputStream(FileResolver.java:171)
    io.vertx.core.impl.FileResolver.unpackFromJarURL(FileResolver.java:180)
    io.vertx.core.impl.FileResolver.resolveFile(FileResolver.java:121)
    io.vertx.core.impl.VertxImpl.resolveFile(VertxImpl.java:657)
    io.vertx.core.file.impl.FileSystemImpl$6.perform(FileSystemImpl.java:517)
    io.vertx.core.file.impl.FileSystemImpl$6.perform(FileSystemImpl.java:514)
    io.vertx.core.file.impl.FileSystemImpl.propsBlocking(FileSystemImpl.java:150)
    io.vertx.ext.web.handler.impl.StaticHandlerImpl.lambda$getFileProps$4(StaticHandlerImpl.java:264)
cescoffier added a commit to cescoffier/vert.x that referenced this issue Jan 6, 2016
* It should decode the url before opening the file input stream as it may contains %20 characters for spaces.
* Add a test suite configuration to load files from a jar files that is located in a directory containing spaces (uses a TCCL switch to append it to the class path)

Signed-off-by: Clement Escoffier <clement.escoffier@gmail.com>
vietj added a commit that referenced this issue Jan 7, 2016
@vietj vietj closed this as completed Jan 7, 2016
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