cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject git commit: ninja fix for missing buffer offsets in CASSANDRA-5884
Date Wed, 14 Aug 2013 12:08:35 GMT
Updated Branches:
  refs/heads/cassandra-2.0 9e846d9ff -> 65f189b9d


ninja fix for missing buffer offsets in CASSANDRA-5884


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/65f189b9
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/65f189b9
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/65f189b9

Branch: refs/heads/cassandra-2.0
Commit: 65f189b9d0520ce9d6a2ed8742d227e60a3e76d4
Parents: 9e846d9
Author: Jake Luciani <jake@apache.org>
Authored: Wed Aug 14 08:07:41 2013 -0400
Committer: Jake Luciani <jake@apache.org>
Committed: Wed Aug 14 08:07:54 2013 -0400

----------------------------------------------------------------------
 src/java/org/apache/cassandra/io/util/Memory.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/65f189b9/src/java/org/apache/cassandra/io/util/Memory.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/io/util/Memory.java b/src/java/org/apache/cassandra/io/util/Memory.java
index b98dded..91c601d 100644
--- a/src/java/org/apache/cassandra/io/util/Memory.java
+++ b/src/java/org/apache/cassandra/io/util/Memory.java
@@ -96,7 +96,7 @@ public class Memory
         long end = memoryOffset + count;
         checkPosition(end - 1);
 
-        unsafe.copyMemory(buffer, BYTE_ARRAY_BASE_OFFSET, null, peer + memoryOffset, count);
+        unsafe.copyMemory(buffer, BYTE_ARRAY_BASE_OFFSET + bufferOffset, null, peer + memoryOffset,
count);
     }
 
     public byte getByte(long offset)
@@ -138,7 +138,7 @@ public class Memory
         long end = memoryOffset + count;
         checkPosition(end - 1);
 
-        unsafe.copyMemory(null, peer + memoryOffset, buffer, BYTE_ARRAY_BASE_OFFSET, count);
+        unsafe.copyMemory(null, peer + memoryOffset, buffer, BYTE_ARRAY_BASE_OFFSET + bufferOffset,
count);
     }
 
     private void checkPosition(long offset)


Mime
View raw message