diff options
author | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2007-06-11 13:48:37 +0000 |
---|---|---|
committer | ph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15> | 2007-06-11 13:48:37 +0000 |
commit | e8712385c5173623fdca4091fa3ad20139b4dab8 (patch) | |
tree | 97d5962c1decd24772f4c33a6f3ada422cde262f | |
parent | 6cd094c7b56880c59c20914f08f739d56a859fa6 (diff) | |
download | pcre-e8712385c5173623fdca4091fa3ad20139b4dab8.tar.gz |
Inserted some (unsigned int) casts to kill compiler warnings.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@176 2f5784b3-3f2a-0410-8824-cb99058d5e15
-rw-r--r-- | ChangeLog | 2 | ||||
-rw-r--r-- | pcre_compile.c | 10 |
2 files changed, 9 insertions, 3 deletions
@@ -57,6 +57,8 @@ Version 7.2 05-June-07 bit of new cunning has reduced the workspace needed for groups with alternatives. The 1000-alternative test pattern now uses 12 bytes of workspace instead of running out of the 4096 that are available. + +10. Inserted some missing (unsigned int) casts to get rid of compiler warnings. Version 7.1 24-Apr-07 diff --git a/pcre_compile.c b/pcre_compile.c index 2deb2d1..e412eef 100644 --- a/pcre_compile.c +++ b/pcre_compile.c @@ -2680,14 +2680,18 @@ for (;; ptr++) unsigned int origd = d; while (get_othercase_range(&cc, origd, &occ, &ocd)) { - if (occ >= c && ocd <= d) continue; /* Skip embedded ranges */ + if (occ >= (unsigned int)c && + ocd <= (unsigned int)d) + continue; /* Skip embedded ranges */ - if (occ < c && ocd >= c - 1) /* Extend the basic range */ + if (occ < (unsigned int)c && + ocd >= (unsigned int)c - 1) /* Extend the basic range */ { /* if there is overlap, */ c = occ; /* noting that if occ < c */ continue; /* we can't have ocd > d */ } /* because a subrange is */ - if (ocd > d && occ <= d + 1) /* always shorter than */ + if (ocd > (unsigned int)d && + occ <= (unsigned int)d + 1) /* always shorter than */ { /* the basic range. */ d = ocd; continue; |