mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
coverity: fixes
This commit is contained in:
parent
4692c1a7ee
commit
69fbc272f0
3 changed files with 19 additions and 4 deletions
|
@ -192,6 +192,13 @@ lwsl_info("context created\n");
|
|||
#endif
|
||||
#endif
|
||||
|
||||
if (context->max_fds < 0) {
|
||||
lwsl_err("%s: problem getting process max files\n",
|
||||
__func__);
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (info->count_threads)
|
||||
context->count_threads = info->count_threads;
|
||||
else
|
||||
|
|
|
@ -646,7 +646,11 @@ utf8_fail:
|
|||
|
||||
/* if pmd not enabled, in == out */
|
||||
|
||||
if (n == PMDR_DID_NOTHING || n == PMDR_UNKNOWN)
|
||||
if (n == PMDR_DID_NOTHING
|
||||
#if !defined(LWS_WITHOUT_EXTENSIONS)
|
||||
|| n == PMDR_UNKNOWN
|
||||
#endif
|
||||
)
|
||||
pmdrx.eb_in.len -= pmdrx.eb_out.len;
|
||||
|
||||
m = wsi->protocol->callback(wsi,
|
||||
|
|
|
@ -692,11 +692,15 @@ utf8_fail:
|
|||
|
||||
/* if pmd not enabled, in == out */
|
||||
|
||||
if (n == PMDR_DID_NOTHING ||
|
||||
n == PMDR_UNKNOWN)
|
||||
if (n == PMDR_DID_NOTHING
|
||||
#if !defined(LWS_WITHOUT_EXTENSIONS)
|
||||
||
|
||||
n == PMDR_UNKNOWN
|
||||
#endif
|
||||
)
|
||||
pmdrx.eb_in.len -= pmdrx.eb_out.len;
|
||||
|
||||
if (!wsi->wsistate_pre_close &&
|
||||
if (!wsi->wsistate_pre_close &&
|
||||
(pmdrx.eb_out.len >= 0 ||
|
||||
callback_action == LWS_CALLBACK_RECEIVE_PONG ||
|
||||
n == PMDR_EMPTY_FINAL)) {
|
||||
|
|
Loading…
Add table
Reference in a new issue