Kaydet (Commit) 66f4347a authored tarafından rbuj's avatar rbuj Kaydeden (comit) David Tardon

jfreereport_libloader: [deprecation] toURL() in File has been deprecated

http://docs.oracle.com/javase/6/docs/api/java/io/File.html#toURL()

Change-Id: I5ff457cdbeff0049a9e31d6aa66dd973289d5f05
Reviewed-on: https://gerrit.libreoffice.org/10506Reviewed-by: 's avatarDavid Tardon <dtardon@redhat.com>
Tested-by: 's avatarDavid Tardon <dtardon@redhat.com>
üst d3293105
...@@ -9,3 +9,26 @@ ...@@ -9,3 +9,26 @@
} }
/** /**
--- misc/libloader-1.1.6/source/org/pentaho/reporting/libraries/resourceloader/loader/file/FileResourceLoader.java 2010-04-27 16:07:00.000000000 +0200
+++ misc/build/libloader-1.1.6/source/org/pentaho/reporting/libraries/resourceloader/loader/file/FileResourceLoader.java 2014-07-24 15:11:26.000000000 +0200
@@ -19,6 +19,7 @@
import java.io.File;
import java.io.IOException;
+import java.lang.SecurityException;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.HashMap;
@@ -170,7 +171,11 @@
final File file = (File) key.getIdentifier();
try
{
- return file.toURL();
+ return file.toURI().toURL();
+ }
+ catch (SecurityException e)
+ {
+ return null;
}
catch (MalformedURLException e)
{
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment