From 2339237cc8d7ceb743c61522cbd3822a45932ea0 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Sat, 11 Mar 2017 08:39:22 -0500 Subject: [PATCH] filter: use SIZE_MAX for size_t The backing type is a size_t, so use SIZE_MAX to represent infinity. Signed-off-by: Mathieu Desnoyers --- lttng-filter-interpreter.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lttng-filter-interpreter.c b/lttng-filter-interpreter.c index a09b0417..f4d5a946 100644 --- a/lttng-filter-interpreter.c +++ b/lttng-filter-interpreter.c @@ -726,7 +726,7 @@ uint64_t lttng_filter_interpret_bytecode(void *filter_data, ret = -EINVAL; goto end; } - estack_ax(stack, top)->u.s.seq_len = UINT_MAX; + estack_ax(stack, top)->u.s.seq_len = SIZE_MAX; estack_ax(stack, top)->u.s.literal_type = ESTACK_STRING_LITERAL_TYPE_NONE; estack_ax(stack, top)->u.s.user = 0; @@ -790,7 +790,7 @@ uint64_t lttng_filter_interpret_bytecode(void *filter_data, dbg_printk("load string %s\n", insn->data); estack_push(stack, top, ax, bx); estack_ax(stack, top)->u.s.str = insn->data; - estack_ax(stack, top)->u.s.seq_len = UINT_MAX; + estack_ax(stack, top)->u.s.seq_len = SIZE_MAX; estack_ax(stack, top)->u.s.literal_type = ESTACK_STRING_LITERAL_TYPE_PLAIN; estack_ax(stack, top)->u.s.user = 0; @@ -805,7 +805,7 @@ uint64_t lttng_filter_interpret_bytecode(void *filter_data, dbg_printk("load globbing pattern %s\n", insn->data); estack_push(stack, top, ax, bx); estack_ax(stack, top)->u.s.str = insn->data; - estack_ax(stack, top)->u.s.seq_len = UINT_MAX; + estack_ax(stack, top)->u.s.seq_len = SIZE_MAX; estack_ax(stack, top)->u.s.literal_type = ESTACK_STRING_LITERAL_TYPE_STAR_GLOB; estack_ax(stack, top)->u.s.user = 0; @@ -870,7 +870,7 @@ uint64_t lttng_filter_interpret_bytecode(void *filter_data, ret = -EINVAL; goto end; } - estack_ax(stack, top)->u.s.seq_len = UINT_MAX; + estack_ax(stack, top)->u.s.seq_len = SIZE_MAX; estack_ax(stack, top)->u.s.literal_type = ESTACK_STRING_LITERAL_TYPE_NONE; estack_ax(stack, top)->u.s.user = 0; @@ -920,7 +920,7 @@ uint64_t lttng_filter_interpret_bytecode(void *filter_data, ret = -EINVAL; goto end; } - estack_ax(stack, top)->u.s.seq_len = UINT_MAX; + estack_ax(stack, top)->u.s.seq_len = SIZE_MAX; estack_ax(stack, top)->u.s.literal_type = ESTACK_STRING_LITERAL_TYPE_NONE; estack_ax(stack, top)->u.s.user = 1; -- 2.34.1