diff options
| author | Fabio Alessandrelli | 2017-01-17 09:22:56 +0100 |
|---|---|---|
| committer | Fabio Alessandrelli | 2017-03-22 20:01:41 +0100 |
| commit | 603105df189699c62b9462839302dae7d9a090de (patch) | |
| tree | 2d13651d170b9836c098a8188b1e4b17667c2e6c /drivers/unix/stream_peer_tcp_posix.cpp | |
| parent | aeffe74a27fbe83f9f3da2672e2b62efe1255bf0 (diff) | |
| download | godot-603105df189699c62b9462839302dae7d9a090de.tar.gz godot-603105df189699c62b9462839302dae7d9a090de.tar.zst godot-603105df189699c62b9462839302dae7d9a090de.zip | |
Diffstat (limited to 'drivers/unix/stream_peer_tcp_posix.cpp')
| -rw-r--r-- | drivers/unix/stream_peer_tcp_posix.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/unix/stream_peer_tcp_posix.cpp b/drivers/unix/stream_peer_tcp_posix.cpp index 7ebcc34c0..779d9e427 100644 --- a/drivers/unix/stream_peer_tcp_posix.cpp +++ b/drivers/unix/stream_peer_tcp_posix.cpp @@ -142,7 +142,7 @@ void StreamPeerTCPPosix::set_socket(int p_sockfd, IP_Address p_host, int p_port, Error StreamPeerTCPPosix::connect(const IP_Address &p_host, uint16_t p_port) { - ERR_FAIL_COND_V(p_host == IP_Address(), ERR_INVALID_PARAMETER); + ERR_FAIL_COND_V(!p_host.is_valid(), ERR_INVALID_PARAMETER); sock_type = p_host.is_ipv4() ? IP::TYPE_IPV4 : IP::TYPE_IPV6; sockfd = _socket_create(sock_type, SOCK_STREAM, IPPROTO_TCP); |
