You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@labs.apache.org by ka...@apache.org on 2013/07/20 20:13:52 UTC
svn commit: r1505177 -
/labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java
Author: kayyagari
Date: Sat Jul 20 18:13:52 2013
New Revision: 1505177
URL: http://svn.apache.org/r1505177
Log:
o reverted the allowDuplicate flag to int value
o fixed the offset comparision (the default value was set to -1 in a previous commit)
Modified:
labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java
Modified: labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java
URL: http://svn.apache.org/viewvc/labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java?rev=1505177&r1=1505176&r2=1505177&view=diff
==============================================================================
--- labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java (original)
+++ labs/mavibot/trunk/mavibot/src/main/java/org/apache/mavibot/btree/RecordManager.java Sat Jul 20 18:13:52 2013
@@ -518,9 +518,9 @@ public class RecordManager
BTreeFactory.setValueSerializer( btree, valueSerializerFqcn );
// The BTree allowDuplicates flag
- byte allowDuplicates = readByte( pageIos, dataPos );
+ int allowDuplicates = readInt( pageIos, dataPos );
btree.setAllowDuplicates( allowDuplicates != 0 );
- dataPos += BYTE_SIZE;
+ dataPos += INT_SIZE;
// Now, init the BTree
btree.init();
@@ -2115,8 +2115,8 @@ public class RecordManager
// skip the page with offset 0, this is the first in-memory root page that
// was copied during first insert in a BTree.
- // a Node or Leaf will *never* have 0 as its offset
- if ( firstOffset == 0 )
+ // a Node or Leaf will *never* have 0 or -1 as its offset
+ if ( firstOffset == NO_PAGE )
{
continue;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org