summaryrefslogtreecommitdiff
path: root/java
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2006-04-12 16:01:30 +0000
committerTom Tromey <tromey@redhat.com>2006-04-12 16:01:30 +0000
commit2bd218052e98b154d4383d2d6d881d70e46eb3f1 (patch)
treec4412514bbbfed08c511181ffafccea4092f6e29 /java
parente2fcada9ec7e995d6c6bcbbd1e10bcb4b99695a4 (diff)
downloadclasspath-2bd218052e98b154d4383d2d6d881d70e46eb3f1.tar.gz
PR classpath/27131:
* java/util/BitSet.java (get): Early return if to==from.
Diffstat (limited to 'java')
-rw-r--r--java/util/BitSet.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/java/util/BitSet.java b/java/util/BitSet.java
index ce88794f5..f1b5aaa06 100644
--- a/java/util/BitSet.java
+++ b/java/util/BitSet.java
@@ -365,7 +365,7 @@ public class BitSet implements Cloneable, Serializable
throw new IndexOutOfBoundsException();
BitSet bs = new BitSet(to - from);
int lo_offset = from >>> 6;
- if (lo_offset >= bits.length)
+ if (lo_offset >= bits.length || to == from)
return bs;
int lo_bit = from & LONG_MASK;