Avoid (s)size_t for portability

This commit is contained in:
Kim Woelders
2018-10-11 14:52:55 +02:00
parent 2d993212c5
commit 44ddf67386
3 changed files with 8 additions and 8 deletions
+3 -3
View File
@@ -121,18 +121,18 @@ static void _telnet_handle_opt(tn_ctx_t * tcc, int opt,
}
}
int telnet_rx(tn_ctx_t * tcc, char *buf, size_t * plen)
int telnet_rx(tn_ctx_t * tcc, char *buf, int *plen)
{
char *s, *p;
unsigned char *pu;
size_t len, rem;
int len, rem;
int np, nd;
int b1, b2;
len = *plen;
tcc->bytes_rx += len;
if (len < (size_t) tcc->off_rx)
if (len < (int)tcc->off_rx)
tcc->off_rx = 0;
for (s = buf + tcc->off_rx, rem = len - tcc->off_rx; rem > 0; s = p)