[warnings] fix signed/unsigned compare warnings

This commit is contained in:
Armin Novak
2026-01-08 14:12:43 +01:00
committed by akallabeth
parent 3f336a3470
commit 164dfef442
3 changed files with 3 additions and 3 deletions

View File

@@ -1403,7 +1403,7 @@ BOOL client_auto_reconnect_ex(freerdp* instance, BOOL (*window_events)(freerdp*
default:
break;
}
for (UINT32 x = 0; x < delay / 10; x++)
for (SSIZE_T x = 0; x < delay / 10; x++)
{
if (!IFCALLRESULT(TRUE, window_events, instance))
{

View File

@@ -256,7 +256,7 @@ static int transport_bio_named_puts(BIO* bio, const char* str)
WINPR_ASSERT(bio);
WINPR_ASSERT(str);
const int max = (INT_MAX > SIZE_MAX) ? SIZE_MAX : INT_MAX;
const size_t max = (INT_MAX > SIZE_MAX) ? SIZE_MAX : INT_MAX;
const size_t len = strnlen(str, max);
if (len >= max)
return -1;

View File

@@ -251,7 +251,7 @@ static int bio_rdp_tls_puts(BIO* bio, const char* str)
if (!str)
return 0;
const int max = (INT_MAX > SIZE_MAX) ? SIZE_MAX : INT_MAX;
const size_t max = (INT_MAX > SIZE_MAX) ? SIZE_MAX : INT_MAX;
const size_t size = strnlen(str, max);
if (size >= max)
return -1;