mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-16 00:00:07 +01:00
coverity 83665 fail on null buffer
Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
parent
cd838506a9
commit
adc720dfb5
1 changed files with 3 additions and 1 deletions
|
@ -214,8 +214,10 @@ int libwebsocket_client_rx_sm(struct libwebsocket *wsi, unsigned char c)
|
|||
|
||||
case LWS_RXPS_PAYLOAD_UNTIL_LENGTH_EXHAUSTED:
|
||||
|
||||
if (!wsi->u.ws.rx_user_buffer)
|
||||
if (!wsi->u.ws.rx_user_buffer) {
|
||||
lwsl_err("NULL client rx_user_buffer\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
if ((!wsi->u.ws.this_frame_masked) || wsi->u.ws.all_zero_nonce)
|
||||
wsi->u.ws.rx_user_buffer[LWS_SEND_BUFFER_PRE_PADDING +
|
||||
|
|
Loading…
Add table
Reference in a new issue