summaryrefslogtreecommitdiff
path: root/src/socket.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/socket.cc')
-rw-r--r--src/socket.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/socket.cc b/src/socket.cc
index c01e31d..c5a2575 100644
--- a/src/socket.cc
+++ b/src/socket.cc
@@ -31,6 +31,11 @@
/*
* $Log$
+ * Revision 1.6 2005/06/02 15:03:23 deva
+ *
+ * Fixed crash in network.cc if socket not connected.
+ * Added option to skop ecery second frame in player
+ *
* Revision 1.5 2005/05/03 17:13:25 deva
* Fixed some missong Info object references.
*
@@ -120,6 +125,7 @@ Socket Socket::slisten()
(socklen_t*)&csalen);
if (s.ssocket < 0) {
+ s.connected = false;
err = 1;
info->error("Socket: accept() failed! %s", strerror(errno));
return s;
@@ -134,6 +140,7 @@ Socket Socket::slisten()
int Socket::sconnect(char *ip)
{
if(err) {
+ connected = false;
info->error("Socket: No socket present!");
return err;
}
@@ -144,6 +151,7 @@ int Socket::sconnect(char *ip)
err = connect(ssocket, (struct sockaddr*)&socketaddr, sizeof(socketaddr));
if (err) {
+ connected = false;
info->error("Socket: connect() failed! %s", strerror(errno));
return err;
}