equal
deleted
inserted
replaced
24 */ |
24 */ |
25 |
25 |
26 package java.util.zip; |
26 package java.util.zip; |
27 |
27 |
28 import java.util.Date; |
28 import java.util.Date; |
|
29 import sun.misc.BootClassLoaderHook; |
29 |
30 |
30 /** |
31 /** |
31 * This class is used to represent a ZIP file entry. |
32 * This class is used to represent a ZIP file entry. |
32 * |
33 * |
33 * @author David Connelly |
34 * @author David Connelly |
107 * @param time the entry modification time in number of milliseconds |
108 * @param time the entry modification time in number of milliseconds |
108 * since the epoch |
109 * since the epoch |
109 * @see #getTime() |
110 * @see #getTime() |
110 */ |
111 */ |
111 public void setTime(long time) { |
112 public void setTime(long time) { |
112 // fix for bug 6625963: we bypass time calculations while Kernel is |
113 // Same value as defined in sun.jkernel.DownloadManager.KERNEL_STATIC_MODTIME |
113 // downloading bundles, since they aren't necessary and would cause |
114 // to avoid direct reference to DownoadManager class. Need to revisit |
114 // the Kernel core to depend upon the (very large) time zone data |
115 // if this is needed any more (see comment in the DownloadManager class) |
115 if (sun.misc.VM.isBootedKernelVM() && |
116 final int KERNEL_STATIC_MODTIME = 10000000; |
116 sun.jkernel.DownloadManager.isCurrentThreadDownloading()) { |
117 BootClassLoaderHook hook = BootClassLoaderHook.getHook(); |
117 this.time = sun.jkernel.DownloadManager.KERNEL_STATIC_MODTIME; |
118 if (hook != null && hook.isCurrentThreadPrefetching()) { |
|
119 // fix for bug 6625963: we bypass time calculations while Kernel is |
|
120 // downloading bundles, since they aren't necessary and would cause |
|
121 // the Kernel core to depend upon the (very large) time zone data |
|
122 this.time = KERNEL_STATIC_MODTIME; |
118 } else { |
123 } else { |
119 this.time = javaToDosTime(time); |
124 this.time = javaToDosTime(time); |
120 } |
125 } |
121 } |
126 } |
122 |
127 |