aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/grep/regex/tre-fastmatch.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/grep/regex/tre-fastmatch.c')
-rw-r--r--usr.bin/grep/regex/tre-fastmatch.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/grep/regex/tre-fastmatch.c b/usr.bin/grep/regex/tre-fastmatch.c
index 9c5aab1e78d4..e6a35ff06731 100644
--- a/usr.bin/grep/regex/tre-fastmatch.c
+++ b/usr.bin/grep/regex/tre-fastmatch.c
@@ -163,7 +163,7 @@ static int fastcmp(const fastmatch_t *fg, const void *data,
shift = bc; \
else \
{ \
- ts = ((long)u - v < 0) ? 0 : (u - v); \
+ ts = (u >= v) ? (u - v) : 0; \
shift = MAX(ts, bc); \
shift = MAX(shift, gs); \
if (shift == gs) \