From 32946417b72391f0b71784503d38e72ff4fa6371 Mon Sep 17 00:00:00 2001 From: Eric Scharff Date: Thu, 11 Oct 2007 16:42:33 -0600 Subject: [PATCH] Fixed subtle bug in getLong() --- classpath/java/nio/ByteBuffer.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/classpath/java/nio/ByteBuffer.java b/classpath/java/nio/ByteBuffer.java index ba3560482e..38cd1993f6 100644 --- a/classpath/java/nio/ByteBuffer.java +++ b/classpath/java/nio/ByteBuffer.java @@ -177,8 +177,8 @@ public class ByteBuffer { public long getLong() { checkGet(8); - long l = getInt() << 32; - l |= getInt() & 0xffffffff; + long l = (long)getInt() << 32; + l |= (long)getInt() & 0xffffffff; return l; }