summaryrefslogtreecommitdiff
path: root/annotations/generate_annotated_java_files.py
diff options
context:
space:
mode:
authorPrzemyslaw Szczepaniak <pszczepaniak@google.com>2016-06-27 13:01:39 +0100
committerPrzemyslaw Szczepaniak <pszczepaniak@google.com>2016-07-12 10:07:06 +0000
commitbf34d8378762aa4d97c30c86ef95502e5d85ed3e (patch)
tree5640fbb7f50d4a520adc373ee6c3c0314c1247c3 /annotations/generate_annotated_java_files.py
parentbe1425dd93c4128018d934246a36ee57f2a5e2cc (diff)
Fix Unsafe#park for large wait-time values.
jsr166.LockSupportTest#testParkNeg_parkUntilBlocker fails if the delay between the tests System.currentTimeMillis is called at least 2ms behind the Unsafe#park. This is caused by underflow to large positive value when subtracting current time from the method argument. This change fixes it by not doing subtraction before comparison. parkUntil takes arguments in milliseconds and is implemented as a call to parkFor, which takes arguments in nanoseconds. If parkUntil argument will overflow during conversion to nanoseconds, it's clamped on max value (~292 years). Bug: 29746125 Change-Id: Ie0b3923ce4567415bf6478552c51eb31ac4aec62
Diffstat (limited to 'annotations/generate_annotated_java_files.py')
0 files changed, 0 insertions, 0 deletions