[Groonga-commit] groonga/groonga at 7e4a6e1 [master] Support MessagePack < 1 again

Back to archive index

Kouhei Sutou null+****@clear*****
Thu Apr 5 13:11:28 JST 2018


Kouhei Sutou	2018-04-05 13:11:28 +0900 (Thu, 05 Apr 2018)

  New Revision: 7e4a6e18b4508d112f6d178c0d3d8946faa5ce6b
  https://github.com/groonga/groonga/commit/7e4a6e18b4508d112f6d178c0d3d8946faa5ce6b

  Message:
    Support MessagePack < 1 again

  Modified files:
    lib/options.c

  Modified: lib/options.c (+2 -2)
===================================================================
--- lib/options.c    2018-04-05 12:25:57 +0900 (d2130f63c)
+++ lib/options.c    2018-04-05 13:11:28 +0900 (af1add534)
@@ -311,8 +311,8 @@ grn_options_get(grn_ctx *ctx,
       for (i = 0; i < map->size; i++) {
         msgpack_object_kv *kv = map->ptr;
         if (kv->key.type == MSGPACK_OBJECT_STR &&
-            kv->key.via.str.size == name_length &&
-            memcmp(kv->key.via.str.ptr, name, name_length) == 0) {
+            MSGPACK_OBJECT_STR_SIZE(&(kv->key)) == name_length &&
+            memcmp(MSGPACK_OBJECT_STR_PTR(&(kv->key)), name, name_length) == 0) {
           if (kv->val.type == MSGPACK_OBJECT_ARRAY) {
             grn_msgpack_unpack_array_internal(ctx,
                                               &(kv->val.via.array),
-------------- next part --------------
HTML����������������������������...
URL: https://lists.osdn.me/mailman/archives/groonga-commit/attachments/20180405/3406d47c/attachment-0001.htm 



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