Use SIZE_MAX instead of -1ULL for size_t parameter
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Sat, 11 Mar 2017 13:44:42 +0000 (08:44 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Sat, 11 Mar 2017 13:44:42 +0000 (08:44 -0500)
strutils_star_glob_match() receives a size_t. Passing -1ULL truncates
the value implicitly on systems where size_t is 32-bit. It is cleaner to
use SIZE_T.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
lttng-events.c

index 6bfe710f57ea24b9d2da90fc4de04f96347da325..95a79cf75dc10de27daf335b927043f9231bfa29 100644 (file)
@@ -1146,7 +1146,7 @@ static
 int lttng_match_enabler_star_glob(const char *desc_name,
                const char *pattern)
 {
-       if (!strutils_star_glob_match(pattern, -1ULL, desc_name, -1ULL))
+       if (!strutils_star_glob_match(pattern, SIZE_MAX, desc_name, SIZE_MAX))
                return 0;
        return 1;
 }
This page took 0.028181 seconds and 4 git commands to generate.