[Groonga-commit] pgroonga/pgroonga at 4dba7bf [master] Fix a bug that large block number in ctid is overflowed

Back to archive index

Kouhei Sutou null+****@clear*****
Sat May 23 18:45:12 JST 2015


Kouhei Sutou	2015-05-23 18:45:12 +0900 (Sat, 23 May 2015)

  New Revision: 4dba7bf8b0f5cdd8adda61509e6e7939a0b26ee1
  https://github.com/pgroonga/pgroonga/commit/4dba7bf8b0f5cdd8adda61509e6e7939a0b26ee1

  Message:
    Fix a bug that large block number in ctid is overflowed

  Modified files:
    pgroonga.c

  Modified: pgroonga.c (+1 -1)
===================================================================
--- pgroonga.c    2015-05-23 17:09:56 +0900 (f962b15)
+++ pgroonga.c    2015-05-23 18:45:12 +0900 (716eaa8)
@@ -932,7 +932,7 @@ CtidToUInt64(ItemPointer ctid)
 
 	blockNumber = ItemPointerGetBlockNumber(ctid);
 	offsetNumber = ItemPointerGetOffsetNumber(ctid);
-	return (blockNumber << 16 | offsetNumber);
+	return (((uint64)blockNumber << 16) | ((uint64)offsetNumber));
 }
 
 static ItemPointerData
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index