提交 27728894 编写于 作者: M mchung

6899851: Regression causes new dependency to jkernel

Summary: Replaced sun.jkernel.DownloadManager calls with BootClassLoaderHook
Reviewed-by: bae, asaha
上级 66c77730
...@@ -865,7 +865,7 @@ public class ICC_Profile implements Serializable { ...@@ -865,7 +865,7 @@ public class ICC_Profile implements Serializable {
case ColorSpace.CS_PYCC: case ColorSpace.CS_PYCC:
synchronized(ICC_Profile.class) { synchronized(ICC_Profile.class) {
if (PYCCprofile == null) { if (PYCCprofile == null) {
if (!sun.jkernel.DownloadManager.isJREComplete() || if (BootClassLoaderHook.getHook() != null ||
standardProfileExists("PYCC.pf")) standardProfileExists("PYCC.pf"))
{ {
ProfileDeferralInfo pInfo = ProfileDeferralInfo pInfo =
...@@ -1835,19 +1835,6 @@ public class ICC_Profile implements Serializable { ...@@ -1835,19 +1835,6 @@ public class ICC_Profile implements Serializable {
} }
} }
if (!f.isFile()) { /* try the directory of built-in profiles */
dir = System.getProperty("java.home") +
File.separatorChar + "lib" + File.separatorChar + "cmm";
fullPath = dir + File.separatorChar + fileName;
f = new File(fullPath);
if (!f.isFile()) {
//make sure file was installed in the kernel mode
BootClassLoaderHook hook = BootClassLoaderHook.getHook();
if (hook.getHook() != null) {
hook.prefetchFile("lib/cmm/"+fileName);
}
}
}
if ((f == null) || (!f.isFile())) { if ((f == null) || (!f.isFile())) {
/* try the directory of built-in profiles */ /* try the directory of built-in profiles */
f = getStandardProfileFile(fileName); f = getStandardProfileFile(fileName);
...@@ -1871,11 +1858,10 @@ public class ICC_Profile implements Serializable { ...@@ -1871,11 +1858,10 @@ public class ICC_Profile implements Serializable {
File f = new File(fullPath); File f = new File(fullPath);
if (!f.isFile()) { if (!f.isFile()) {
//make sure file was installed in the kernel mode //make sure file was installed in the kernel mode
try { BootClassLoaderHook hook = BootClassLoaderHook.getHook();
//kernel uses platform independent paths => if (hook != null) {
// should not use platform separator char hook.prefetchFile("lib/cmm/"+fileName);
sun.jkernel.DownloadManager.downloadFile("lib/cmm/"+fileName); }
} catch (IOException ioe) {}
} }
return (f.isFile() && isChildOf(f, dir)) ? f : null; return (f.isFile() && isChildOf(f, dir)) ? f : null;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册