mirror of
https://github.com/curl/curl.git
synced 2026-08-08 18:22:55 +03:00
vtls: remove int typecast for sizeof()
V220 Suspicious sequence of types castings: memsize -> 32-bit integer -> memsize. The value being cast: 'sizeof (buf->data)'. curl\lib\vtls\vtls.c 2025 https://pvs-studio.com/en/docs/warnings/v220/ Closes #10928
This commit is contained in:
parent
c59b5b3c87
commit
a1763648a5
1 changed files with 1 additions and 1 deletions
|
|
@ -2022,7 +2022,7 @@ CURLcode Curl_alpn_to_proto_str(struct alpn_proto_buf *buf,
|
|||
len = strlen(spec->entries[i]);
|
||||
if(len >= ALPN_NAME_MAX)
|
||||
return CURLE_FAILED_INIT;
|
||||
if(off + len + 2 >= (int)sizeof(buf->data))
|
||||
if(off + len + 2 >= sizeof(buf->data))
|
||||
return CURLE_FAILED_INIT;
|
||||
if(off)
|
||||
buf->data[off++] = ',';
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue