Hi Lars,

Thanks for submitting the patch.  Your change looks good.  Some minor nits:

jdk/src/share/classes/sun/management/RuntimeImpl.java
The previous VM startup time in milliseconds is no longer needed in this version. You can remove the vmStartupTime variable and getStartTime method from this class.

jdk/src/share/classes/sun/management/VMManagement.java
jdk/src/share/classes/sun/management/VMManagementImpl.java
jdk/src/share/native/sun/management/VMManagementImpl.c
   Similar to the comment above, you can remove the getStartupTime method.

jdk/src/share/native/sun/management/VMManagementImpl.c
line 194: need one additional space to align with the word "env" in the above line.

jdk/test/java/lang/management/RuntimeMXBean/NegativeUptime.java
This test would be useful if someone wants to verify this manually. We can attach this test in the bug report to be available for others to use. This test would not be appropriate for our test harness since the tests are run with non-privilege mode. In addition, changing the date on a test machine might be problematic to other tests running on the system which we should avoid.

There are some functionality tests testing this API. I will run those tests on our machines and see if this fixes the problem. Can you send me a tarball of these modified files so that I can build a JDK with your fix? I'll let you know when I'm done testing to proceed with the hg push.
Thanks
Mandy

Lars Westergren wrote:

Hello,

First attempt at posting a solution. Sorry about the
"nbproject/project.xml" in the webrev index page, a bit embarrassed
that I can't seem to get Mercurial to ignore it.

The test is OS dependent, and of course requires that the process that
executes jtreg is root or at least has the right to set back the OS
clock.

Cheers,
Lars


Reply via email to