aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Paul Saman <jpsaman@videolan.org>2014-01-27 15:08:20 (GMT)
committerJean-Paul Saman <jpsaman@videolan.org>2014-01-27 15:10:13 (GMT)
commitd9bf9c7570ddd48b5334fdc95f14c625178871d7 (patch)
treea49dd4de0b5ec441a5886be5f3494dc9d0b9260c
parent31f3c4582b7a47e3bcbc8fcc2a95f56794f6f997 (diff)
dvbinfo: tcp fixes
-rw-r--r--examples/dvbinfo/tcp.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/dvbinfo/tcp.c b/examples/dvbinfo/tcp.c
index 481f273..cae9849 100644
--- a/examples/dvbinfo/tcp.c
+++ b/examples/dvbinfo/tcp.c
@@ -80,7 +80,7 @@ int tcp_close(int fd)
{
int result = 0;
- result = shutdown(fd, 2);
+ result = shutdown(fd, SHUT_RDWR);
if (result < 0)
perror("tcp shutdown error");
return result;
@@ -149,6 +149,8 @@ int tcp_open(const char *ipaddress, int port)
perror( "tcp connect error" );
continue;
}
+
+ break; /* success */
}
freeaddrinfo(addr);

Privacy Policy