diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/tag/Pool.cxx | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/tag/Pool.cxx b/src/tag/Pool.cxx index e977c6784..e5a6d57f2 100644 --- a/src/tag/Pool.cxx +++ b/src/tag/Pool.cxx @@ -114,10 +114,7 @@ tag_pool_get_item(TagType type, StringView value) noexcept auto slot_p = tag_value_slot_p(type, value); for (auto slot = *slot_p; slot != nullptr; slot = slot->next) { if (slot->item.type == type && - /* strncmp() only works if there are no null - bytes, which FixTagString() has already ensured - at this point */ - strncmp(value.data, slot->item.value, value.size) == 0 && + value.Equals(slot->item.value) && slot->ref < TagPoolSlot::MAX_REF) { assert(slot->ref > 0); ++slot->ref; |