Skip to content

Exception when downloading file with parameters #4480

@tobiasdiez

Description

@tobiasdiez

JabRef version 5dev on Windows 10

Steps to reproduce the behavior:

  1. Open entry editor > General fields tab
  2. Using the "Download button" next to the file field, try to download an url with parameters like https://www.jstor.org/stable/pdfplus/10.2307/2373250.pdf?acceptTC=true
  3. Get exception
java.nio.file.InvalidPathException: Illegal char <?> at index 65: Smale1965 - An Infinite Dimensional Version of Sard's Theorem.pdf?accepttc=true
  at sun.nio.fs.WindowsPathParser.normalize(Unknown Source)
  at sun.nio.fs.WindowsPathParser.parse(Unknown Source)
  at sun.nio.fs.WindowsPathParser.parse(Unknown Source)
  at sun.nio.fs.WindowsPath.parse(Unknown Source)
  at sun.nio.fs.WindowsFileSystem.getPath(Unknown Source)
  at sun.nio.fs.AbstractPath.resolve(Unknown Source)
  at org.jabref.gui.fieldeditors.LinkedFileViewModel.lambda$download$375(LinkedFileViewModel.java:370)
  at org.jabref.gui.util.BackgroundTask$1.call(BackgroundTask.java:46)
  at org.jabref.gui.util.BackgroundTask$3.call(BackgroundTask.java:171)
  at org.jabref.gui.util.DefaultTaskExecutor$1.call(DefaultTaskExecutor.java:116)
  at javafx.concurrent.Task$TaskCallable.call(Task.java:1423)
  at java.util.concurrent.FutureTask.run(Unknown Source)
  at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
  at java.util.concurrent.FutureTask.run(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
  at java.lang.Thread.run(Unknown Source)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions