[Groonga-commit] groonga/grnxx at f3c93e5 [master] Fix a bug of grnxx::map::HashTable.

Back to archive index

susumu.yata null+****@clear*****
Fri Jun 21 19:28:35 JST 2013


susumu.yata	2013-06-21 19:28:35 +0900 (Fri, 21 Jun 2013)

  New Revision: f3c93e55c00b03c3336f883b75b5534a208a28f1
  https://github.com/groonga/grnxx/commit/f3c93e55c00b03c3336f883b75b5534a208a28f1

  Message:
    Fix a bug of grnxx::map::HashTable.
    
    grnxx::map::hash_table::KeyIDArray could not be unlinked.

  Modified files:
    lib/grnxx/map/hash_table/key_id_array.hpp

  Modified: lib/grnxx/map/hash_table/key_id_array.hpp (+5 -1)
===================================================================
--- lib/grnxx/map/hash_table/key_id_array.hpp    2013-06-21 13:42:54 +0900 (8e90c91)
+++ lib/grnxx/map/hash_table/key_id_array.hpp    2013-06-21 19:28:35 +0900 (a328d0d)
@@ -113,7 +113,11 @@ class KeyIDArray {
 
   // Unlink an array.
   static bool unlink(Storage *storage, uint32_t storage_node_id) {
-    return ArrayImpl::unlink(storage, storage_node_id);
+    std::unique_ptr<KeyIDArray> array(open(storage, storage_node_id));
+    if (!array) {
+      return false;
+    }
+    return storage->unlink_node(storage_node_id);
   }
 
   // Return the number of values in each page.
-------------- next part --------------
HTML����������������������������...
下载 



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