mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
coverity: use function comments to clear false positives
This commit is contained in:
parent
db760fa164
commit
ba8402b43f
4 changed files with 4 additions and 1 deletions
|
@ -728,7 +728,7 @@ lws_create_vhost(struct lws_context *context,
|
|||
p = getenv("http_proxy");
|
||||
if (p) {
|
||||
lws_strncpy(buf, p, sizeof(buf));
|
||||
|
||||
/* coverity[tainted_scalar] */
|
||||
lws_set_proxy(vh, buf);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -850,6 +850,7 @@ lws_client_interpret_server_handshake(struct lws *wsi)
|
|||
*/
|
||||
lwsl_err("Redirect failed\n");
|
||||
cce = "HS: Redirect failed";
|
||||
/* coverity[reverse_inull] */
|
||||
if (wsi)
|
||||
goto bail3;
|
||||
|
||||
|
|
|
@ -163,6 +163,7 @@ lws_generate_client_ws_handshake(struct lws *wsi, char *p, const char *conn1)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/* coverity[tainted_scalar] */
|
||||
lws_b64_encode_string(hash, 16, key_b64, sizeof(key_b64));
|
||||
|
||||
p += sprintf(p, "Upgrade: websocket\x0d\x0a"
|
||||
|
|
|
@ -169,6 +169,7 @@ scan_upload_dir(struct vhd_deaddrop *vhd)
|
|||
if (de->d_name[strlen(de->d_name) - 1] == '~')
|
||||
continue;
|
||||
|
||||
/* coverity[toctou] */
|
||||
if (stat(filepath, &s))
|
||||
continue;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue