RFR JDK-8206389: JarEntry.setCreation/LastAccessTime without setLastModifiedTime causes Invalid CEN header
xueming.shen at oracle.com
Sat Jul 7 03:50:14 UTC 2018
On 7/6/18, 5:43 PM, Martin Buchholz wrote:
> I would use different timestamps for the 4 possible times used in this
> test, if only to make it clearer which value comes from where.
webrev has been updated accordingly.
> + // ze.setLastModifiedTime(now);
> + ze.setTime(now.toMillis());
> setTime only sets the DOS time? Which only has a granularity of 2
> seconds? If so, how do you get back the same value you put in if the
> current second is odd? Or am I misunderstanding the test?
no misunderstanding, good catch. The test does fail when hits the odd
added a special "check" version for the 2 second granularity set/getTime().
More information about the core-libs-dev