|
41 | 41 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
42 | 42 | */
|
43 | 43 |
|
44 |
| -#define DISABLE_SIGN_COMPARE_WARNINGS |
45 |
| - |
46 | 44 | #include "xinclude.h"
|
47 | 45 |
|
48 | 46 | #define MAX_PTR UINT_MAX
|
@@ -108,7 +106,7 @@ static int scanA(struct histindex *index, int line1, int count1)
|
108 | 106 | unsigned int chain_len;
|
109 | 107 | struct record **rec_chain, *rec;
|
110 | 108 |
|
111 |
| - for (ptr = LINE_END(1); line1 <= ptr; ptr--) { |
| 109 | + for (ptr = LINE_END(1); (unsigned int)line1 <= ptr; ptr--) { |
112 | 110 | tbl_idx = TABLE_HASH(index, 1, ptr);
|
113 | 111 | rec_chain = index->records + tbl_idx;
|
114 | 112 | rec = *rec_chain;
|
@@ -183,14 +181,14 @@ static int try_lcs(struct histindex *index, struct region *lcs, int b_ptr,
|
183 | 181 | be = bs;
|
184 | 182 | rc = rec->cnt;
|
185 | 183 |
|
186 |
| - while (line1 < as && line2 < bs |
| 184 | + while ((unsigned int)line1 < as && (unsigned int)line2 < bs |
187 | 185 | && CMP(index, 1, as - 1, 2, bs - 1)) {
|
188 | 186 | as--;
|
189 | 187 | bs--;
|
190 | 188 | if (1 < rc)
|
191 | 189 | rc = XDL_MIN(rc, CNT(index, as));
|
192 | 190 | }
|
193 |
| - while (ae < LINE_END(1) && be < LINE_END(2) |
| 191 | + while (ae < (unsigned int)LINE_END(1) && be < (unsigned int)LINE_END(2) |
194 | 192 | && CMP(index, 1, ae + 1, 2, be + 1)) {
|
195 | 193 | ae++;
|
196 | 194 | be++;
|
@@ -315,7 +313,7 @@ static int histogram_diff(xpparam_t const *xpp, xdfenv_t *env,
|
315 | 313 | if (count1 <= 0 && count2 <= 0)
|
316 | 314 | return 0;
|
317 | 315 |
|
318 |
| - if (LINE_END(1) >= MAX_PTR) |
| 316 | + if ((unsigned int)LINE_END(1) >= MAX_PTR) |
319 | 317 | return -1;
|
320 | 318 |
|
321 | 319 | if (!count1) {
|
|
0 commit comments