diff options
Diffstat (limited to 'modules/websocket')
-rw-r--r-- | modules/websocket/SCsub | 2 | ||||
-rw-r--r-- | modules/websocket/wsl_peer.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/modules/websocket/SCsub b/modules/websocket/SCsub index 3f834471e5..8b469fe5be 100644 --- a/modules/websocket/SCsub +++ b/modules/websocket/SCsub @@ -25,7 +25,7 @@ elif env["builtin_wslay"]: env_ws.Prepend(CPPPATH=[thirdparty_dir]) env_ws.Append(CPPDEFINES=["HAVE_CONFIG_H"]) - if env["platform"] == "windows" or env["platform"] == "uwp": + if env["platform"] == "windows": env_ws.Append(CPPDEFINES=["HAVE_WINSOCK2_H"]) else: env_ws.Append(CPPDEFINES=["HAVE_NETINET_IN_H"]) diff --git a/modules/websocket/wsl_peer.cpp b/modules/websocket/wsl_peer.cpp index a127a6b75a..38cb614847 100644 --- a/modules/websocket/wsl_peer.cpp +++ b/modules/websocket/wsl_peer.cpp @@ -600,7 +600,7 @@ ssize_t WSLPeer::_wsl_send_callback(wslay_event_context_ptr ctx, const uint8_t * } int WSLPeer::_wsl_genmask_callback(wslay_event_context_ptr ctx, uint8_t *buf, size_t len, void *user_data) { - ERR_FAIL_COND_V(!_static_rng, WSLAY_ERR_CALLBACK_FAILURE); + ERR_FAIL_NULL_V(_static_rng, WSLAY_ERR_CALLBACK_FAILURE); Error err = _static_rng->get_random_bytes(buf, len); ERR_FAIL_COND_V(err != OK, WSLAY_ERR_CALLBACK_FAILURE); return 0; @@ -676,7 +676,7 @@ void WSLPeer::poll() { } if (ready_state == STATE_OPEN || ready_state == STATE_CLOSING) { - ERR_FAIL_COND(!wsl_ctx); + ERR_FAIL_NULL(wsl_ctx); int err = 0; if ((err = wslay_event_recv(wsl_ctx)) != 0 || (err = wslay_event_send(wsl_ctx)) != 0) { // Error close. |