mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8285519: Change usages of TimeUnit.convert to TimeUnit.toXXX
Reviewed-by: rriggs
This commit is contained in:
parent
e7d52e25a2
commit
e833c1d179
4 changed files with 24 additions and 22 deletions
|
@ -1230,7 +1230,7 @@ public final class NioSocketImpl extends SocketImpl implements PlatformSocketImp
|
|||
private static long tryLock(ReentrantLock lock, long timeout, TimeUnit unit) {
|
||||
assert timeout > 0;
|
||||
boolean interrupted = false;
|
||||
long nanos = NANOSECONDS.convert(timeout, unit);
|
||||
long nanos = unit.toNanos(timeout);
|
||||
long remainingNanos = nanos;
|
||||
long startNanos = System.nanoTime();
|
||||
boolean acquired = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue