[Tarantool-patches] [PATCH 1/2] tuple: fix multikey field JSON access crash

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Wed Aug 12 23:34:35 MSK 2020


>> +        if (offset_slot_hint != NULL) {
>>               *offset_slot_hint = offset_slot;
>> +            /*
>> +             * Hint is never requested for a multikey field without
>> +             * providing a concrete multikey index.
>> +             */
>> +            assert(!field->is_multikey_part ||
>> +                   (multikey_idx != MULTIKEY_NONE &&
>> +                field->is_multikey_part));
> The last '&& field->is_multikey_part' is excess.

Indeed, a stupid mistake. Somewhy I was sure it was needed yesterday.
Dropped now.

====================
 			assert(!field->is_multikey_part ||
-			       (multikey_idx != MULTIKEY_NONE &&
-				field->is_multikey_part));
+			       multikey_idx != MULTIKEY_NONE);
====================


More information about the Tarantool-patches mailing list