cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r1028587 - in /cassandra/branches/cassandra-0.7: CHANGES.txt src/java/org/apache/cassandra/db/marshal/IntegerType.java
Date Fri, 29 Oct 2010 01:55:53 GMT
Author: jbellis
Date: Fri Oct 29 01:55:53 2010
New Revision: 1028587

URL: http://svn.apache.org/viewvc?rev=1028587&view=rev
Log:
fix IntegerType.getString.  patch by Jim Ancona and jbellis for CASSANDRA-1681

Modified:
    cassandra/branches/cassandra-0.7/CHANGES.txt
    cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/db/marshal/IntegerType.java

Modified: cassandra/branches/cassandra-0.7/CHANGES.txt
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.7/CHANGES.txt?rev=1028587&r1=1028586&r2=1028587&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.7/CHANGES.txt (original)
+++ cassandra/branches/cassandra-0.7/CHANGES.txt Fri Oct 29 01:55:53 2010
@@ -3,6 +3,7 @@ dev
  * log type of dropped messages (CASSANDRA-1677)
  * upgrade to SLF4J 1.6.1
  * fix ByteBuffer bug in ExpiringColumn.updateDigest (CASSANDRA-1679)
+ * fix IntegerType.getString (CASSANDRA-1681)
 
 
 0.7.0-beta3

Modified: cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/db/marshal/IntegerType.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/db/marshal/IntegerType.java?rev=1028587&r1=1028586&r2=1028587&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/db/marshal/IntegerType.java
(original)
+++ cassandra/branches/cassandra-0.7/src/java/org/apache/cassandra/db/marshal/IntegerType.java
Fri Oct 29 01:55:53 2010
@@ -21,6 +21,8 @@ package org.apache.cassandra.db.marshal;
 
 import java.nio.ByteBuffer;
 
+import org.apache.thrift.TBaseHelper;
+
 public final class IntegerType extends AbstractType
 {
     public static final IntegerType instance = new IntegerType();
@@ -118,6 +120,6 @@ public final class IntegerType extends A
         if (bytes.remaining() == 0)
             return "empty";
 
-        return new java.math.BigInteger(bytes.array()).toString(10);
+        return new java.math.BigInteger(TBaseHelper.byteBufferToByteArray(bytes)).toString(10);
     }
 }



Mime
View raw message