From 3b1d18c3062d5e5beed615ae19fc23ec03cb47a8 Mon Sep 17 00:00:00 2001 From: Jaroslav Kysela Date: Wed, 10 Sep 2014 19:57:49 +0200 Subject: [PATCH] idnode: Fix PT_S64 and PT_TIME filtering --- src/idnode.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/idnode.c b/src/idnode.c index a2e065d7..3f20e096 100644 --- a/src/idnode.c +++ b/src/idnode.c @@ -407,6 +407,8 @@ idnode_get_s64 case PT_S64: *s64 = *(int64_t*)ptr; return 0; + case PT_TIME: + *s64 = *(time_t*)ptr; default: break; } @@ -650,11 +652,9 @@ idnode_filter break; } } else if (f->type == IF_NUM || f->type == IF_BOOL) { - uint32_t u32; int64_t a, b; - if (idnode_get_u32(in, f->key, &u32)) + if (idnode_get_s64(in, f->key, &a)) return 1; - a = u32; b = (f->type == IF_NUM) ? f->u.n : f->u.b; switch (f->comp) { case IC_IN: