RFR(M): 7147848: [macosx] com.sun.management.UnixOperatingSystem uses hardcoded dummy values

Dmitry Samersoff Dmitry.Samersoff at oracle.com
Tue Apr 10 15:04:41 PDT 2012


Staffan,


1. MacosxOperatingSystem.c

49         return 0;

Probably it should be -1 here.


NIT: 133     if (gettimeofday(&now, NULL)) {

if (gettimeofday(&now, NULL) < 0) { - IMHO is more readable.


-Dmitry





On 2012-04-03 17:39, Staffan Larsen wrote:
> Please review the following fix:
>
> webrev: http://cr.openjdk.java.net/~sla/7147848/webrev.00/
> bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7147848
>
> This fix implements the missing functionality in UnixOperatingSystem for
> Mac OS X. Any feedback on the implementation is welcome as I am not very
> familiar with the APIs in Mac OS X.
>
> I have verified that the changes build on all platforms through JPRT.
> The correctness has been verified manually by looking in JConsole and
> running the tests in test/java/lang/management/OperatingSystemMXBean
> test/com/sun/management/OperatingSystemMXBean.
>
> Thanks,
> /Staffan


-- 
Dmitry Samersoff
Java Hotspot development team, SPB04
* There will come soft rains ...


More information about the serviceability-dev mailing list