From b25a4f8231f3ded44038ea454a3d4c6a2dc9217d Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 15 Mar 2009 00:32:18 +0000 Subject: (svn r15718) -Cleanup: apply some comment coding style on the rest of the sources too --- src/network/core/core.cpp | 4 ++-- src/network/core/host.cpp | 2 +- src/network/core/os_abstraction.h | 14 +++++++------- src/network/core/udp.cpp | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) (limited to 'src/network/core') diff --git a/src/network/core/core.cpp b/src/network/core/core.cpp index 645259053..1c0ecad40 100644 --- a/src/network/core/core.cpp +++ b/src/network/core/core.cpp @@ -52,8 +52,8 @@ bool NetworkCoreInitialize() } } } -#endif // __AMIGA__ -#endif // __MORPHOS__ / __AMIGA__ +#endif /* __AMIGA__ */ +#endif /* __MORPHOS__ / __AMIGA__ */ /* Let's load the network in windows */ #ifdef WIN32 diff --git a/src/network/core/host.cpp b/src/network/core/host.cpp index c88c96f55..bcd317f8c 100644 --- a/src/network/core/host.cpp +++ b/src/network/core/host.cpp @@ -200,7 +200,7 @@ void NetworkFindBroadcastIPs(uint32 *broadcast, int limit) /* Now display to the debug all the detected ips */ DEBUG(net, 3, "Detected broadcast addresses:"); for (int i = 0; broadcast[i] != 0; i++) { - DEBUG(net, 3, "%d) %s", i, inet_ntoa(*(struct in_addr *)&broadcast[i])); //inet_ntoa(inaddr)); + DEBUG(net, 3, "%d) %s", i, inet_ntoa(*(struct in_addr *)&broadcast[i])); // inet_ntoa(inaddr)); } } diff --git a/src/network/core/os_abstraction.h b/src/network/core/os_abstraction.h index 481f8ff33..8d5723639 100644 --- a/src/network/core/os_abstraction.h +++ b/src/network/core/os_abstraction.h @@ -50,7 +50,7 @@ typedef unsigned long in_addr_t; # include # if defined(__BEOS__) && defined(BEOS_NET_SERVER) # include -# include // snooze() +# include /* snooze() */ # include typedef unsigned long in_addr_t; # define INADDR_NONE INADDR_BROADCAST @@ -85,7 +85,7 @@ typedef unsigned long in_addr_t; # include # include # include -#endif // UNIX +#endif /* UNIX */ #ifdef __BEOS__ typedef int socklen_t; @@ -146,13 +146,13 @@ typedef unsigned long in_addr_t; /* MorphOS and Amiga stuff */ #if defined(__MORPHOS__) || defined(__AMIGA__) # include -# include // required for Open/CloseLibrary() +# include /* required for Open/CloseLibrary() */ /* MorphOS defines his network functions with UBYTE arrays while we * use char arrays. This gives tons of unneeded warnings */ # define UBYTE char # if defined(__MORPHOS__) -# include // FIO* defines -# include // SIO* defines +# include /* FIO* defines */ +# include /* SIO* defines */ # include # else /* __AMIGA__ */ # include @@ -174,7 +174,7 @@ typedef unsigned long in_addr_t; extern struct MsgPort *TimerPort; extern struct timerequest *TimerRequest; # endif -#endif // __MORPHOS__ || __AMIGA__ +#endif /* __MORPHOS__ || __AMIGA__ */ static inline bool SetNonBlocking(SOCKET d) { @@ -193,7 +193,7 @@ static inline bool SetNonBlocking(SOCKET d) static inline bool SetNoDelay(SOCKET d) { /* XXX should this be done at all? */ -#if !defined(BEOS_NET_SERVER) // not implemented on BeOS net_server +#if !defined(BEOS_NET_SERVER) /* not implemented on BeOS net_server */ int b = 1; /* The (const char*) cast is needed for windows */ return setsockopt(d, IPPROTO_TCP, TCP_NODELAY, (const char*)&b, sizeof(b)) == 0; diff --git a/src/network/core/udp.cpp b/src/network/core/udp.cpp index 8035446c0..6c921ae0a 100644 --- a/src/network/core/udp.cpp +++ b/src/network/core/udp.cpp @@ -50,7 +50,7 @@ bool NetworkUDPSocketHandler::Listen(const uint32 host, const uint16 port, const if (broadcast) { /* Enable broadcast */ unsigned long val = 1; -#ifndef BEOS_NET_SERVER // will work around this, some day; maybe. +#ifndef BEOS_NET_SERVER /* will work around this, some day; maybe. */ setsockopt(this->sock, SOL_SOCKET, SO_BROADCAST, (char *) &val , sizeof(val)); #endif } @@ -233,7 +233,7 @@ void NetworkUDPSocketHandler::Recv_NetworkGameInfo(Packet *p, NetworkGameInfo *i *dst = c; dst = &c->next; } - } /* Fallthrough */ + } // Fallthrough case 3: info->game_date = Clamp(p->Recv_uint32(), 0, MAX_DATE); info->start_date = Clamp(p->Recv_uint32(), 0, MAX_DATE); -- cgit v1.2.3-54-g00ecf