Skip to content

Commit

Permalink
FIX: signed/unsigned mismatch warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Oldes committed Jul 3, 2023
1 parent 23b8c81 commit ad1f2a0
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/core/l-scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,7 @@

/***********************************************************************
**
*/ const REBYTE *Scan_Raw_String(const REBYTE *src, SCAN_STATE *scan_state, int num)
*/ const REBYTE *Scan_Raw_String(const REBYTE *src, SCAN_STATE *scan_state, REBLEN num)
/*
** Scan a raw string (without any modifications).
** Eliminates need of double escaping and allowes unmatched braces.
Expand Down
2 changes: 1 addition & 1 deletion src/core/n-image.c
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ double weighted_rgb_color_distance(long r1, long g1, long b1, long r2, long g2,
} else {
pixels = VAL_IMAGE_WIDE(img1) * VAL_IMAGE_HIGH(img1);

for (int i = 0; i < pixels; i++, rgba1 += 4, rgba2 += 4) {
for (REBCNT i = 0; i < pixels; i++, rgba1 += 4, rgba2 += 4) {
dist += weighted_rgb_color_distance(
rgba1[C_R], rgba1[C_G], rgba1[C_B],
rgba2[C_R], rgba2[C_G], rgba2[C_B]
Expand Down
2 changes: 1 addition & 1 deletion src/core/s-unicode.c
Original file line number Diff line number Diff line change
Expand Up @@ -808,7 +808,7 @@ Boolean isLegalUTF8Sequence(const UTF8 *source, const UTF8 *sourceEnd) {
if (uni) {
// not using wcslen, because on some systems wchar_t has 4 bytes!
cnt = 0;
while (*up++ != 0 && cnt < max) cnt++;
while (*up++ != 0 && cnt < (REBLEN)max) cnt++;
up = (REBUNI*)src;
} else
cnt = LEN_BYTES(bp);
Expand Down

0 comments on commit ad1f2a0

Please sign in to comment.