X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=blobdiff_plain;f=src%2Fcore%2Fstore_lookup.c;h=f72e26dd4e6f4e153ebc2728c4f0b5d067e4fd4d;hp=4862905b3366d4fa4455a95ddc80a5bedd8ee652;hb=d8d03b18f0e0a4c39e2adec3cc2cd093d52c1f93;hpb=c603d51e4ad3adea8d3f3afc8b796e49c180030b diff --git a/src/core/store_lookup.c b/src/core/store_lookup.c index 4862905..f72e26d 100644 --- a/src/core/store_lookup.c +++ b/src/core/store_lookup.c @@ -301,7 +301,7 @@ match_isnull(sdb_store_matcher_t *m, sdb_store_obj_t *obj, sdb_data_t v = SDB_DATA_INIT; int status; - assert((m->type == MATCHER_ISNULL) || (m->type == MATCHER_ISNNULL)); + assert(m->type == MATCHER_ISNULL); if (ISNULL_M(m)->expr->type) { /* TODO: this might hide real errors; @@ -319,8 +319,6 @@ match_isnull(sdb_store_matcher_t *m, sdb_store_obj_t *obj, if (ISNULL_M(m)->expr->type) sdb_data_free_datum(&v); - if (m->type == MATCHER_ISNNULL) - return !status; return status; } /* match_isnull */ @@ -341,7 +339,6 @@ matchers[] = { /* unary operators */ match_isnull, - match_isnull, /* ary operators */ match_cmp, @@ -456,7 +453,7 @@ static int isnull_matcher_init(sdb_object_t *obj, va_list ap) { M(obj)->type = va_arg(ap, int); - if ((M(obj)->type != MATCHER_ISNULL) && (M(obj)->type != MATCHER_ISNNULL)) + if (M(obj)->type != MATCHER_ISNULL) return -1; ISNULL_M(obj)->expr = va_arg(ap, sdb_store_expr_t *); @@ -637,13 +634,6 @@ sdb_store_isnull_matcher(sdb_store_expr_t *expr) MATCHER_ISNULL, expr)); } /* sdb_store_isnull_matcher */ -sdb_store_matcher_t * -sdb_store_isnnull_matcher(sdb_store_expr_t *expr) -{ - return M(sdb_object_create("isnull-matcher", isnull_type, - MATCHER_ISNNULL, expr)); -} /* sdb_store_isnnull_matcher */ - sdb_store_matcher_op_cb sdb_store_parse_matcher_op(const char *op) {