[warnings] fixed sign-compare

This commit is contained in:
akallabeth
2024-09-04 09:55:55 +02:00
parent 2fc791fe9b
commit 5e123735fa
10 changed files with 16 additions and 15 deletions

View File

@@ -409,7 +409,7 @@ static char* pf_config_decode_base64(const char* data, const char* name, size_t*
while (*end == '-')
end++;
const size_t s = MIN(ARRAYSIZE(hdr) - 1, end - data);
const size_t s = MIN(ARRAYSIZE(hdr) - 1ULL, (size_t)(end - data));
memcpy(hdr, data, s);
}

View File

@@ -676,12 +676,12 @@ static int x11_shadow_blend_cursor(x11ShadowSubsystem* subsystem)
pDstData = surface->data;
nDstStep = surface->scanline;
for (int y = 0; y < nHeight; y++)
for (size_t y = 0; y < nHeight; y++)
{
const BYTE* pSrcPixel = &pSrcData[((nYSrc + y) * nSrcStep) + (nXSrc * 4)];
BYTE* pDstPixel = &pDstData[((nYDst + y) * nDstStep) + (nXDst * 4)];
for (int x = 0; x < nWidth; x++)
for (size_t x = 0; x < nWidth; x++)
{
B = *pSrcPixel++;
G = *pSrcPixel++;