From c0598ba4caacc57940cf01d90bc523e976023158 Mon Sep 17 00:00:00 2001 From: Sebastian Harl Date: Thu, 19 Jun 2014 16:41:23 +0200 Subject: [PATCH] store_lookup: Let attribute matchers check the attribute name. --- src/core/store_lookup.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/core/store_lookup.c b/src/core/store_lookup.c index fe98e91..f2d8cc7 100644 --- a/src/core/store_lookup.c +++ b/src/core/store_lookup.c @@ -243,6 +243,9 @@ match_attr(sdb_store_matcher_t *m, sdb_store_base_t *obj) sdb_attribute_t *attr = SDB_ATTR(sdb_llist_iter_get_next(iter)); char buf[sdb_data_strlen(&attr->value) + 1]; + if (ATTR_M(m)->name && strcasecmp(ATTR_M(m)->name, SDB_OBJ(attr)->name)) + continue; + if (sdb_data_format(&attr->value, buf, sizeof(buf), SDB_UNQUOTED) <= 0) return 0; if (match_obj_name(&ATTR_M(m)->value, buf)) { -- 2.30.2