From: Sebastian Harl Date: Fri, 21 Feb 2014 01:46:33 +0000 (+0100) Subject: store: Fixed data format error detection. X-Git-Tag: sysdb-0.1.0~194 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d31d779192a8f55a2d4899c2a78bf007cee887cb;p=sysdb.git store: Fixed data format error detection. --- diff --git a/src/core/store_lookup.c b/src/core/store_lookup.c index 64145ee..089b99f 100644 --- a/src/core/store_lookup.c +++ b/src/core/store_lookup.c @@ -148,7 +148,7 @@ match_attr(attr_matcher_t *m, sdb_store_base_t *obj) sdb_attribute_t *attr = SDB_ATTR(obj); char buf[sdb_data_strlen(&attr->value) + 1]; - if (sdb_data_format(&attr->value, buf, sizeof(buf), SDB_UNQUOTED)) + if (sdb_data_format(&attr->value, buf, sizeof(buf), SDB_UNQUOTED) <= 0) return -1; return match_name(&m->value, buf); }