Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
c356ec5e
Commit
c356ec5e
authored
Jan 16, 2017
by
Fabio Alessandrelli
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix bug in windows TCP poll function
Bug introduced when implementing TCP disconnection detection. (too much yank-paste). Fixes #7545
parent
0c80bc25
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
4 deletions
+1
-4
stream_peer_winsock.cpp
platform/windows/stream_peer_winsock.cpp
+1
-4
No files found.
platform/windows/stream_peer_winsock.cpp
View file @
c356ec5e
...
...
@@ -98,7 +98,7 @@ Error StreamPeerWinsock::_poll_connection(bool p_block) const {
return
OK
;
};
if
(
err
no
==
WSAEINPROGRESS
||
errno
==
WSAEALREADY
)
{
if
(
err
==
WSAEINPROGRESS
||
err
==
WSAEALREADY
)
{
return
OK
;
}
...
...
@@ -136,13 +136,11 @@ Error StreamPeerWinsock::write(const uint8_t* p_data,int p_bytes, int &r_sent, b
int
data_to_send
=
p_bytes
;
const
uint8_t
*
offset
=
p_data
;
if
(
sockfd
==
-
1
)
return
FAILED
;
errno
=
0
;
int
total_sent
=
0
;
while
(
data_to_send
)
{
int
sent_amount
=
send
(
sockfd
,
(
const
char
*
)
offset
,
data_to_send
,
0
);
//printf("Sent TCP data of %d bytes, errno %d\n", sent_amount, errno);
if
(
sent_amount
==
-
1
)
{
...
...
@@ -195,7 +193,6 @@ Error StreamPeerWinsock::read(uint8_t* p_buffer, int p_bytes,int &r_received, bo
int
to_read
=
p_bytes
;
int
total_read
=
0
;
errno
=
0
;
while
(
to_read
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment