[Groonga-commit] groonga/groonga at 170762f [master] hash: add missing queue init on open

Back to archive index

Kouhei Sutou null+****@clear*****
Tue Jan 30 09:48:49 JST 2018


Kouhei Sutou	2018-01-30 09:48:49 +0900 (Tue, 30 Jan 2018)

  New Revision: 170762fefbb3cc86d047e1dbd086d83bb630e2a5
  https://github.com/groonga/groonga/commit/170762fefbb3cc86d047e1dbd086d83bb630e2a5

  Message:
    hash: add missing queue init on open

  Modified files:
    lib/hash.c

  Modified: lib/hash.c (+9 -0)
===================================================================
--- lib/hash.c    2018-01-30 09:46:14 +0900 (cfc297506)
+++ lib/hash.c    2018-01-30 09:48:49 +0900 (2da4a504d)
@@ -2037,6 +2037,15 @@ grn_hash_open(grn_ctx *ctx, const char *path)
               hash->normalizer = grn_ctx_at(ctx, header->normalizer);
             }
             GRN_PTR_INIT(&(hash->token_filters), GRN_OBJ_VECTOR, GRN_ID_NIL);
+            {
+              grn_table_queue *queue;
+              if (GRN_HASH_IS_LARGE_KEY(hash)) {
+                queue = &(hash->header.large->queue);
+              } else {
+                queue = &(hash->header.normal->queue);
+              }
+              grn_table_queue_init(ctx, queue);
+            }
             hash->obj.header.flags = header->flags;
             return hash;
           } else {
-------------- next part --------------
HTML����������������������������...
URL: https://lists.osdn.me/mailman/archives/groonga-commit/attachments/20180130/f4012908/attachment.htm 



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