summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2023-05-19 08:40:25 +0200
committerGitHub <noreply@github.com>2023-05-19 08:40:25 +0200
commit138882742a95366c833b54035ad58a5764856ffa (patch)
treec8b4e6735ad51daf8c5804463be83ced3700b081 /modules
parent60e8a06d4eec393d0a2fc277bd66f080f55333b6 (diff)
parent5fe254e8f681f400f2ebab187486998f499387f9 (diff)
Merge pull request #77202 from YuriSizov/4.0-cherrypicks
Cherry-picks for the 4.0 branch (future 4.0.3) - 5th batch
Diffstat (limited to 'modules')
-rw-r--r--modules/gdscript/doc_classes/GDScript.xml3
-rw-r--r--modules/websocket/wsl_peer.cpp4
2 files changed, 5 insertions, 2 deletions
diff --git a/modules/gdscript/doc_classes/GDScript.xml b/modules/gdscript/doc_classes/GDScript.xml
index 1a102bd16f..0651d33e66 100644
--- a/modules/gdscript/doc_classes/GDScript.xml
+++ b/modules/gdscript/doc_classes/GDScript.xml
@@ -5,7 +5,8 @@
</brief_description>
<description>
A script implemented in the GDScript programming language. The script extends the functionality of all objects that instantiate it.
- [method new] creates a new instance of the script. [method Object.set_script] extends an existing object, if that object's class matches one of the script's base classes.
+ Calling [method new] creates a new instance of the script. [method Object.set_script] extends an existing object, if that object's class matches one of the script's base classes.
+ If you are looking for GDScript's built-in functions, see [@GDScript] instead.
</description>
<tutorials>
<link title="GDScript documentation index">$DOCS_URL/tutorials/scripting/gdscript/index.html</link>
diff --git a/modules/websocket/wsl_peer.cpp b/modules/websocket/wsl_peer.cpp
index 8a150c8561..aedc82bfcf 100644
--- a/modules/websocket/wsl_peer.cpp
+++ b/modules/websocket/wsl_peer.cpp
@@ -332,7 +332,7 @@ void WSLPeer::_do_client_handshake() {
if (connection == tcp) {
// Start SSL handshake
tls = Ref<StreamPeerTLS>(StreamPeerTLS::create());
- ERR_FAIL_COND_MSG(tls.is_null(), "SSL is not available in this build.");
+ ERR_FAIL_COND(tls.is_null());
if (tls->connect_to_stream(tcp, requested_host, tls_options) != OK) {
close(-1);
return; // Error.
@@ -504,6 +504,8 @@ Error WSLPeer::connect_to_url(const String &p_url, Ref<TLSOptions> p_options) {
path = "/";
}
+ ERR_FAIL_COND_V_MSG(use_tls && !StreamPeerTLS::is_available(), ERR_UNAVAILABLE, "WSS is not available in this build.");
+
requested_url = p_url;
requested_host = host;