mirror of
https://github.com/godotengine/godot.git
synced 2025-01-18 20:40:57 +08:00
Fix bug causing UDP socket to close after the first send if not listening
The ring buffer for receiving packets was not resized in constructor
This commit is contained in:
parent
fa0cb7da0e
commit
68dc969f8c
@ -275,6 +275,7 @@ PacketPeerUDPPosix::PacketPeerUDPPosix() {
|
||||
queue_count=0;
|
||||
peer_port=0;
|
||||
sock_type = IP::TYPE_NONE;
|
||||
rb.resize(8);
|
||||
}
|
||||
|
||||
PacketPeerUDPPosix::~PacketPeerUDPPosix() {
|
||||
|
@ -290,6 +290,7 @@ PacketPeerUDPWinsock::PacketPeerUDPWinsock() {
|
||||
queue_count=0;
|
||||
peer_port=0;
|
||||
sock_type = IP::TYPE_NONE;
|
||||
rb.resize(8);
|
||||
}
|
||||
|
||||
PacketPeerUDPWinsock::~PacketPeerUDPWinsock() {
|
||||
|
Loading…
Reference in New Issue
Block a user