Commit 7439475e authored by Michael Niedermayer's avatar Michael Niedermayer

avformat/network: check ff_socket_nonblock() return and print a debug message

Fixes CID1026744
Fixes CID1026743
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 0f02ea0a
......@@ -281,7 +281,9 @@ int ff_listen_bind(int fd, const struct sockaddr *addr,
closesocket(fd);
ff_socket_nonblock(ret, 1);
if (ff_socket_nonblock(ret, 1) < 0)
av_log(NULL, AV_LOG_DEBUG, "ff_socket_nonblock failed\n");
return ret;
}
......@@ -293,7 +295,8 @@ int ff_listen_connect(int fd, const struct sockaddr *addr,
int ret;
socklen_t optlen;
ff_socket_nonblock(fd, 1);
if (ff_socket_nonblock(fd, 1) < 0)
av_log(NULL, AV_LOG_DEBUG, "ff_socket_nonblock failed\n");
while ((ret = connect(fd, addr, addrlen))) {
ret = ff_neterrno();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment