I am trying to open a text file from an application run on UNIX using java.awt.Desktop 's open() method. If the file to be opened contains "From:" at its beginning, the API, fails by throwing an IOException.
Caused by: java.io.IOException: Failed to show URI:file:/filename.txt
at sun.awt.X11.XDesktopPeer.launch(XDesktopPeer.java:75)
at sun.awt.X11.XDesktopPeer.open(XDesktopPeer.java:43)
at java.awt.Desktop.open(Desktop.java:254)
Removing the colon (:) after "From" in the content makes it work though. The problem does not occur in Windows. Any light on this ?