diff options
author | rubidium <rubidium@openttd.org> | 2007-03-07 11:47:46 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2007-03-07 11:47:46 +0000 |
commit | 36bb92ae241403d61dc7a3e5a1696b615be61395 (patch) | |
tree | 5676d0d54be47c40d975fdeb1026317fc2a010db /src/network | |
parent | a69e3b1c45f12ee6f21a4ac1c8a8f8bc0892f226 (diff) | |
download | openttd-36bb92ae241403d61dc7a3e5a1696b615be61395.tar.xz |
(svn r9050) -Codechange: Foo(void) -> Foo()
Diffstat (limited to 'src/network')
-rw-r--r-- | src/network/core/core.cpp | 4 | ||||
-rw-r--r-- | src/network/core/core.h | 4 | ||||
-rw-r--r-- | src/network/core/packet.cpp | 16 | ||||
-rw-r--r-- | src/network/core/packet.h | 16 | ||||
-rw-r--r-- | src/network/network.cpp | 46 | ||||
-rw-r--r-- | src/network/network.h | 26 | ||||
-rw-r--r-- | src/network/network_client.cpp | 2 | ||||
-rw-r--r-- | src/network/network_client.h | 2 | ||||
-rw-r--r-- | src/network/network_data.h | 4 | ||||
-rw-r--r-- | src/network/network_gamelist.cpp | 2 | ||||
-rw-r--r-- | src/network/network_gamelist.h | 2 | ||||
-rw-r--r-- | src/network/network_gui.cpp | 12 | ||||
-rw-r--r-- | src/network/network_gui.h | 10 | ||||
-rw-r--r-- | src/network/network_server.cpp | 10 | ||||
-rw-r--r-- | src/network/network_server.h | 8 | ||||
-rw-r--r-- | src/network/network_udp.cpp | 14 | ||||
-rw-r--r-- | src/network/network_udp.h | 12 |
17 files changed, 95 insertions, 95 deletions
diff --git a/src/network/core/core.cpp b/src/network/core/core.cpp index 7fb10cfaf..1f60aba80 100644 --- a/src/network/core/core.cpp +++ b/src/network/core/core.cpp @@ -21,7 +21,7 @@ struct Library *SocketBase = NULL; * Initializes the network core (as that is needed for some platforms * @return true if the core has been initialized, false otherwise */ -bool NetworkCoreInitialize(void) +bool NetworkCoreInitialize() { #if defined(__MORPHOS__) || defined(__AMIGA__) /* @@ -72,7 +72,7 @@ bool NetworkCoreInitialize(void) /** * Shuts down the network core (as that is needed for some platforms */ -void NetworkCoreShutdown(void) +void NetworkCoreShutdown() { #if defined(__MORPHOS__) || defined(__AMIGA__) /* free allocated resources */ diff --git a/src/network/core/core.h b/src/network/core/core.h index 990100a69..c07f5ab81 100644 --- a/src/network/core/core.h +++ b/src/network/core/core.h @@ -12,8 +12,8 @@ #include "os_abstraction.h" #include "../../newgrf_config.h" -bool NetworkCoreInitialize(void); -void NetworkCoreShutdown(void); +bool NetworkCoreInitialize(); +void NetworkCoreShutdown(); /** Status of a network client; reasons why a client has quit */ typedef enum { diff --git a/src/network/core/packet.cpp b/src/network/core/packet.cpp index e43908d83..8d85e9ad5 100644 --- a/src/network/core/packet.cpp +++ b/src/network/core/packet.cpp @@ -63,7 +63,7 @@ Packet *NetworkSend_Init(PacketType type) /** * Writes the packet size from the raw packet from packet->size */ -void Packet::PrepareToSend(void) +void Packet::PrepareToSend() { assert(this->cs == NULL && this->next == NULL); @@ -163,7 +163,7 @@ bool Packet::CanReadFromPacket(uint bytes_to_read) /** * Reads the packet size from the raw packet and stores it in the packet->size */ -void Packet::ReadRawPacketSize(void) +void Packet::ReadRawPacketSize() { assert(this->cs != NULL && this->next == NULL); this->size = (PacketSize)this->buffer[0]; @@ -173,7 +173,7 @@ void Packet::ReadRawPacketSize(void) /** * Prepares the packet so it can be read */ -void Packet::PrepareToRead(void) +void Packet::PrepareToRead() { this->ReadRawPacketSize(); @@ -181,12 +181,12 @@ void Packet::PrepareToRead(void) this->pos = sizeof(PacketSize); } -bool Packet::Recv_bool(void) +bool Packet::Recv_bool() { return this->Recv_uint8() != 0; } -uint8 Packet::Recv_uint8(void) +uint8 Packet::Recv_uint8() { uint8 n; @@ -196,7 +196,7 @@ uint8 Packet::Recv_uint8(void) return n; } -uint16 Packet::Recv_uint16(void) +uint16 Packet::Recv_uint16() { uint16 n; @@ -207,7 +207,7 @@ uint16 Packet::Recv_uint16(void) return n; } -uint32 Packet::Recv_uint32(void) +uint32 Packet::Recv_uint32() { uint32 n; @@ -220,7 +220,7 @@ uint32 Packet::Recv_uint32(void) return n; } -uint64 Packet::Recv_uint64(void) +uint64 Packet::Recv_uint64() { uint64 n; diff --git a/src/network/core/packet.h b/src/network/core/packet.h index 47fff6247..295c4e8c2 100644 --- a/src/network/core/packet.h +++ b/src/network/core/packet.h @@ -43,7 +43,7 @@ public: Packet(PacketType type); /* Sending/writing of packets */ - void PrepareToSend(void); + void PrepareToSend(); void Send_bool (bool data); void Send_uint8 (uint8 data); @@ -53,15 +53,15 @@ public: void Send_string(const char* data); /* Reading/receiving of packets */ - void ReadRawPacketSize(void); - void PrepareToRead(void); + void ReadRawPacketSize(); + void PrepareToRead(); bool CanReadFromPacket (uint bytes_to_read); - bool Recv_bool (void); - uint8 Recv_uint8 (void); - uint16 Recv_uint16(void); - uint32 Recv_uint32(void); - uint64 Recv_uint64(void); + bool Recv_bool (); + uint8 Recv_uint8 (); + uint16 Recv_uint16(); + uint32 Recv_uint32(); + uint64 Recv_uint64(); void Recv_string(char* buffer, size_t size); }; diff --git a/src/network/network.cpp b/src/network/network.cpp index 7c7aa9a3a..18fb31ec3 100644 --- a/src/network/network.cpp +++ b/src/network/network.cpp @@ -63,7 +63,7 @@ static byte _network_clients_connected = 0; static uint16 _network_client_index = NETWORK_SERVER_INDEX + 1; /* Some externs / forwards */ -extern void StateGameLoop(void); +extern void StateGameLoop(); // Function that looks up the CI for a given client-index NetworkClientInfo *NetworkFindClientInfoFromIndex(uint16 client_index) @@ -117,7 +117,7 @@ void NetworkGetClientName(char *client_name, size_t size, const NetworkTCPSocket } } -byte NetworkSpectatorCount(void) +byte NetworkSpectatorCount() { NetworkTCPSocketHandler *cs; byte count = 0; @@ -301,7 +301,7 @@ char* GetNetworkErrorMsg(char* buf, NetworkErrorCode err, const char* last) } /* Count the number of active clients connected */ -static uint NetworkCountPlayers(void) +static uint NetworkCountPlayers() { NetworkTCPSocketHandler *cs; uint count = 0; @@ -317,7 +317,7 @@ static uint NetworkCountPlayers(void) static bool _min_players_paused = false; /* Check if the minimum number of players has been reached and pause or unpause the game as appropriate */ -void CheckMinPlayers(void) +void CheckMinPlayers() { if (!_network_dedicated) return; @@ -337,7 +337,7 @@ void CheckMinPlayers(void) } // Find all IP-aliases for this host -static void NetworkFindIPs(void) +static void NetworkFindIPs() { #if !defined(PSP) int i; @@ -717,7 +717,7 @@ static bool NetworkConnect(const char *hostname, int port) } // For the server, to accept new clients -static void NetworkAcceptClients(void) +static void NetworkAcceptClients() { struct sockaddr_in sin; NetworkTCPSocketHandler *cs; @@ -782,7 +782,7 @@ static void NetworkAcceptClients(void) } // Set up the listen socket for the server -static bool NetworkListen(void) +static bool NetworkListen() { SOCKET ls; struct sockaddr_in sin; @@ -826,7 +826,7 @@ static bool NetworkListen(void) } // Close all current connections -static void NetworkClose(void) +static void NetworkClose() { NetworkTCPSocketHandler *cs; @@ -848,7 +848,7 @@ static void NetworkClose(void) } // Inits the network (cleans sockets and stuff) -static void NetworkInitialize(void) +static void NetworkInitialize() { NetworkTCPSocketHandler *cs; @@ -921,7 +921,7 @@ void NetworkAddServer(const char *b) /* Generates the list of manually added hosts from NetworkGameList and * dumps them into the array _network_host_list. This array is needed * by the function that generates the config file. */ -void NetworkRebuildHostList(void) +void NetworkRebuildHostList() { uint i = 0; const NetworkGameList *item = _network_game_list; @@ -968,7 +968,7 @@ bool NetworkClientConnectGame(const char *host, uint16 port) return _networking; } -static void NetworkInitGameInfo(void) +static void NetworkInitGameInfo() { NetworkClientInfo *ci; @@ -1013,7 +1013,7 @@ static void NetworkInitGameInfo(void) ttd_strlcpy(ci->unique_id, _network_unique_id, sizeof(ci->unique_id)); } -bool NetworkServerStart(void) +bool NetworkServerStart() { if (!_network_available) return false; @@ -1060,7 +1060,7 @@ bool NetworkServerStart(void) // The server is rebooting... // The only difference with NetworkDisconnect, is the packets that is sent -void NetworkReboot(void) +void NetworkReboot() { if (_network_server) { NetworkTCPSocketHandler *cs; @@ -1084,7 +1084,7 @@ void NetworkReboot(void) } // We want to disconnect from the host/clients -void NetworkDisconnect(void) +void NetworkDisconnect() { if (_network_server) { NetworkTCPSocketHandler *cs; @@ -1112,7 +1112,7 @@ void NetworkDisconnect(void) } // Receives something from the network -static bool NetworkReceive(void) +static bool NetworkReceive() { NetworkTCPSocketHandler *cs; int n; @@ -1167,7 +1167,7 @@ static bool NetworkReceive(void) } // This sends all buffered commands (if possible) -static void NetworkSend(void) +static void NetworkSend() { NetworkTCPSocketHandler *cs; FOR_ALL_CLIENTS(cs) { @@ -1183,7 +1183,7 @@ static void NetworkSend(void) } // Handle the local-command-queue -static void NetworkHandleLocalQueue(void) +static void NetworkHandleLocalQueue() { CommandPacket *cp, **cp_prev; @@ -1218,7 +1218,7 @@ static void NetworkHandleLocalQueue(void) } -static bool NetworkDoClientLoop(void) +static bool NetworkDoClientLoop() { _frame_counter++; @@ -1259,7 +1259,7 @@ static bool NetworkDoClientLoop(void) } // We have to do some UDP checking -void NetworkUDPGameLoop(void) +void NetworkUDPGameLoop() { if (_network_udp_server) { _udp_server_socket->ReceivePackets(); @@ -1273,7 +1273,7 @@ void NetworkUDPGameLoop(void) // The main loop called from ttd.c // Here we also have to do StateGameLoop if needed! -void NetworkGameLoop(void) +void NetworkGameLoop() { if (!_networking) return; @@ -1318,7 +1318,7 @@ void NetworkGameLoop(void) NetworkSend(); } -static void NetworkGenerateUniqueId(void) +static void NetworkGenerateUniqueId() { md5_state_t state; md5_byte_t digest[16]; @@ -1372,7 +1372,7 @@ void NetworkStartDebugLog(const char *hostname, uint16 port) } /** This tries to launch the network for a given OS */ -void NetworkStartUp(void) +void NetworkStartUp() { DEBUG(net, 3, "[core] starting network..."); @@ -1409,7 +1409,7 @@ void NetworkStartUp(void) } /** This shuts the network down */ -void NetworkShutDown(void) +void NetworkShutDown() { NetworkDisconnect(); NetworkUDPShutdown(); diff --git a/src/network/network.h b/src/network/network.h index 4ea8ce9e7..29fabedaa 100644 --- a/src/network/network.h +++ b/src/network/network.h @@ -153,7 +153,7 @@ VARDEF uint8 _network_min_players; // Minimum number of players for ga void NetworkTCPQueryServer(const char* host, unsigned short port); -byte NetworkSpectatorCount(void); +byte NetworkSpectatorCount(); VARDEF char *_network_host_list[10]; VARDEF char *_network_ban_list[25]; @@ -161,22 +161,22 @@ VARDEF char *_network_ban_list[25]; void ParseConnectionString(const char **player, const char **port, char *connection_string); void NetworkUpdateClientInfo(uint16 client_index); void NetworkAddServer(const char *b); -void NetworkRebuildHostList(void); +void NetworkRebuildHostList(); bool NetworkChangeCompanyPassword(byte argc, char *argv[]); -void NetworkPopulateCompanyInfo(void); +void NetworkPopulateCompanyInfo(); void UpdateNetworkGameWindow(bool unselect); -void CheckMinPlayers(void); +void CheckMinPlayers(); void NetworkStartDebugLog(const char *hostname, uint16 port); -void NetworkStartUp(void); +void NetworkStartUp(); void NetworkUDPCloseAll(); -void NetworkShutDown(void); -void NetworkGameLoop(void); -void NetworkUDPGameLoop(void); -bool NetworkServerStart(void); +void NetworkShutDown(); +void NetworkGameLoop(); +void NetworkUDPGameLoop(); +bool NetworkServerStart(); bool NetworkClientConnectGame(const char *host, uint16 port); -void NetworkReboot(void); -void NetworkDisconnect(void); +void NetworkReboot(); +void NetworkDisconnect(); bool IsNetworkCompatibleVersion(const char *version); @@ -188,8 +188,8 @@ VARDEF bool _network_advertise; ///< is the server advertising to the master se #else /* ENABLE_NETWORK */ /* Network function stubs when networking is disabled */ -static inline void NetworkStartUp(void) {} -static inline void NetworkShutDown(void) {} +static inline void NetworkStartUp() {} +static inline void NetworkShutDown() {} #define _networking 0 #define _network_server 0 diff --git a/src/network/network_client.cpp b/src/network/network_client.cpp index 8c0db339f..2d0a14dcb 100644 --- a/src/network/network_client.cpp +++ b/src/network/network_client.cpp @@ -839,7 +839,7 @@ static NetworkClientPacket* const _network_client_packet[] = { assert_compile(lengthof(_network_client_packet) == PACKET_END); // Is called after a client is connected to the server -void NetworkClient_Connected(void) +void NetworkClient_Connected() { // Set the frame-counter to 0 so nothing happens till we are ready _frame_counter = 0; diff --git a/src/network/network_client.h b/src/network/network_client.h index 7d50b1edd..1778bc8fe 100644 --- a/src/network/network_client.h +++ b/src/network/network_client.h @@ -18,7 +18,7 @@ DEF_CLIENT_SEND_COMMAND(PACKET_CLIENT_ACK); DEF_CLIENT_SEND_COMMAND_PARAM(PACKET_CLIENT_RCON)(const char *pass, const char *command); NetworkRecvStatus NetworkClient_ReadPackets(NetworkTCPSocketHandler *cs); -void NetworkClient_Connected(void); +void NetworkClient_Connected(); #endif /* ENABLE_NETWORK */ diff --git a/src/network/network_data.h b/src/network/network_data.h index 676c9b66c..3c41831fd 100644 --- a/src/network/network_data.h +++ b/src/network/network_data.h @@ -84,7 +84,7 @@ extern NetworkTCPSocketHandler _clients[MAX_CLIENTS]; // Macros to make life a bit more easier #define DEF_CLIENT_RECEIVE_COMMAND(type) NetworkRecvStatus NetworkPacketReceive_ ## type ## _command(Packet *p) -#define DEF_CLIENT_SEND_COMMAND(type) void NetworkPacketSend_ ## type ## _command(void) +#define DEF_CLIENT_SEND_COMMAND(type) void NetworkPacketSend_ ## type ## _command() #define DEF_CLIENT_SEND_COMMAND_PARAM(type) void NetworkPacketSend_ ## type ## _command #define DEF_SERVER_RECEIVE_COMMAND(type) void NetworkPacketReceive_ ## type ## _command(NetworkTCPSocketHandler *cs, Packet *p) #define DEF_SERVER_SEND_COMMAND(type) void NetworkPacketSend_ ## type ## _command(NetworkTCPSocketHandler *cs) @@ -104,7 +104,7 @@ void NetworkCloseClient(NetworkTCPSocketHandler *cs); void CDECL NetworkTextMessage(NetworkAction action, uint16 color, bool self_send, const char *name, const char *str, ...); void NetworkGetClientName(char *clientname, size_t size, const NetworkTCPSocketHandler *cs); uint NetworkCalculateLag(const NetworkTCPSocketHandler *cs); -byte NetworkGetCurrentLanguageIndex(void); +byte NetworkGetCurrentLanguageIndex(); NetworkClientInfo *NetworkFindClientInfoFromIndex(uint16 client_index); NetworkClientInfo *NetworkFindClientInfoFromIP(const char *ip); NetworkTCPSocketHandler *NetworkFindClientStateFromIndex(uint16 client_index); diff --git a/src/network/network_gamelist.cpp b/src/network/network_gamelist.cpp index 4bd5d10b0..2ade288eb 100644 --- a/src/network/network_gamelist.cpp +++ b/src/network/network_gamelist.cpp @@ -89,7 +89,7 @@ enum { }; /** Requeries the (game) servers we have not gotten a reply from */ -void NetworkGameListRequery(void) +void NetworkGameListRequery() { static uint8 requery_cnt = 0; diff --git a/src/network/network_gamelist.h b/src/network/network_gamelist.h index e552ff9cc..83ce10021 100644 --- a/src/network/network_gamelist.h +++ b/src/network/network_gamelist.h @@ -19,6 +19,6 @@ extern NetworkGameList *_network_game_list; NetworkGameList *NetworkGameListAddItem(uint32 ip, uint16 port); void NetworkGameListRemoveItem(NetworkGameList *remove); -void NetworkGameListRequery(void); +void NetworkGameListRequery(); #endif /* NETWORK_GAMELIST_H */ diff --git a/src/network/network_gui.cpp b/src/network/network_gui.cpp index 4457d5b6e..a2f8ab486 100644 --- a/src/network/network_gui.cpp +++ b/src/network/network_gui.cpp @@ -54,7 +54,7 @@ static Listing _ng_sorting; static char _edit_str_buf[150]; static bool _chat_tab_completion_active; -static void ShowNetworkStartServerWindow(void); +static void ShowNetworkStartServerWindow(); static void ShowNetworkLobbyWindow(NetworkGameList *ngl); extern void SwitchMode(int new_mode); @@ -551,7 +551,7 @@ static const WindowDesc _network_game_window_desc = { NetworkGameWindowWndProc, }; -void ShowNetworkGameWindow(void) +void ShowNetworkGameWindow() { static bool first = true; Window *w; @@ -778,7 +778,7 @@ static const WindowDesc _network_start_server_window_desc = { NetworkStartServerWindowWndProc, }; -static void ShowNetworkStartServerWindow(void) +static void ShowNetworkStartServerWindow() { Window *w; DeleteWindowById(WC_NETWORK_WINDOW, 0); @@ -1151,7 +1151,7 @@ static bool CheckClientListHeight(Window *w) } // Finds the amount of actions in the popup and set the height correct -static uint ClientListPopupHeigth(void) { +static uint ClientListPopupHeigth() { int i, num = 0; // Find the amount of actions @@ -1368,7 +1368,7 @@ static void ClientListWndProc(Window *w, WindowEvent *e) } } -void ShowClientList(void) +void ShowClientList() { AllocateWindowDescFront(&_client_list_desc, 0); } @@ -1460,7 +1460,7 @@ static const WindowDesc _network_join_status_window_desc = { NetworkJoinStatusWindowWndProc, }; -void ShowJoinStatusWindow(void) +void ShowJoinStatusWindow() { Window *w; DeleteWindowById(WC_NETWORK_STATUS_WINDOW, 0); diff --git a/src/network/network_gui.h b/src/network/network_gui.h index 650cf2554..06c5eee1c 100644 --- a/src/network/network_gui.h +++ b/src/network/network_gui.h @@ -10,16 +10,16 @@ void ShowNetworkNeedPassword(NetworkPasswordType npt); void ShowNetworkGiveMoneyWindow(PlayerID player); // PlayerID void ShowNetworkChatQueryWindow(DestType type, byte dest); -void ShowJoinStatusWindow(void); -void ShowNetworkGameWindow(void); -void ShowClientList(void); +void ShowJoinStatusWindow(); +void ShowNetworkGameWindow(); +void ShowClientList(); #else /* ENABLE_NETWORK */ /* Network function stubs when networking is disabled */ static inline void ShowNetworkChatQueryWindow(byte desttype, byte dest) {} -static inline void ShowClientList(void) {} -static inline void ShowNetworkGameWindow(void) {} +static inline void ShowClientList() {} +static inline void ShowNetworkGameWindow() {} #endif /* ENABLE_NETWORK */ diff --git a/src/network/network_server.cpp b/src/network/network_server.cpp index 5762550c9..91856ff52 100644 --- a/src/network/network_server.cpp +++ b/src/network/network_server.cpp @@ -1228,7 +1228,7 @@ static NetworkServerPacket* const _network_server_packet[] = { assert_compile(lengthof(_network_server_packet) == PACKET_END); // This update the company_info-stuff -void NetworkPopulateCompanyInfo(void) +void NetworkPopulateCompanyInfo() { char password[NETWORK_PASSWORD_LENGTH]; const Player *p; @@ -1355,7 +1355,7 @@ void NetworkUpdateClientInfo(uint16 client_index) } /* Check if we want to restart the map */ -static void NetworkCheckRestartMap(void) +static void NetworkCheckRestartMap() { if (_network_restart_game_year != 0 && _cur_year >= _network_restart_game_year) { DEBUG(net, 0, "Auto-restarting map. Year %d reached", _cur_year); @@ -1369,7 +1369,7 @@ static void NetworkCheckRestartMap(void) 1) If a company is not protected, it is closed after 1 year (for example) 2) If a company is protected, protection is disabled after 3 years (for example) (and item 1. happens a year later) */ -static void NetworkAutoCleanCompanies(void) +static void NetworkAutoCleanCompanies() { NetworkTCPSocketHandler *cs; const NetworkClientInfo *ci; @@ -1564,12 +1564,12 @@ void NetworkServer_Tick(bool send_frame) NetworkUDPAdvertise(); } -void NetworkServerYearlyLoop(void) +void NetworkServerYearlyLoop() { NetworkCheckRestartMap(); } -void NetworkServerMonthlyLoop(void) +void NetworkServerMonthlyLoop() { NetworkAutoCleanCompanies(); } diff --git a/src/network/network_server.h b/src/network/network_server.h index 3924a6062..aea76f33e 100644 --- a/src/network/network_server.h +++ b/src/network/network_server.h @@ -17,8 +17,8 @@ void NetworkServer_HandleChat(NetworkAction action, DestType type, int dest, con bool NetworkServer_ReadPackets(NetworkTCPSocketHandler *cs); void NetworkServer_Tick(bool send_frame); -void NetworkServerMonthlyLoop(void); -void NetworkServerYearlyLoop(void); +void NetworkServerMonthlyLoop(); +void NetworkServerYearlyLoop(); static inline const char* GetPlayerIP(const NetworkClientInfo* ci) { @@ -31,8 +31,8 @@ static inline const char* GetPlayerIP(const NetworkClientInfo* ci) #else /* ENABLE_NETWORK */ /* Network function stubs when networking is disabled */ -static inline void NetworkServerMonthlyLoop(void) {} -static inline void NetworkServerYearlyLoop(void) {} +static inline void NetworkServerMonthlyLoop() {} +static inline void NetworkServerYearlyLoop() {} #endif /* ENABLE_NETWORK */ diff --git a/src/network/network_udp.cpp b/src/network/network_udp.cpp index 08d207d8b..063a1aef2 100644 --- a/src/network/network_udp.cpp +++ b/src/network/network_udp.cpp @@ -402,7 +402,7 @@ void ClientNetworkUDPSocketHandler::HandleIncomingNetworkGameInfoGRFConfig(GRFCo } // Close UDP connection -void NetworkUDPCloseAll(void) +void NetworkUDPCloseAll() { DEBUG(net, 1, "[udp] closed listeners"); @@ -435,7 +435,7 @@ static void NetworkUDPBroadCast(NetworkUDPSocketHandler *socket) // Request the the server-list from the master server -void NetworkUDPQueryMasterServer(void) +void NetworkUDPQueryMasterServer() { struct sockaddr_in out_addr; @@ -458,7 +458,7 @@ void NetworkUDPQueryMasterServer(void) } // Find all servers -void NetworkUDPSearchGame(void) +void NetworkUDPSearchGame() { // We are still searching.. if (_network_udp_broadcast > 0) return; @@ -504,7 +504,7 @@ void NetworkUDPQueryServer(const char* host, unsigned short port, bool manually) } /* Remove our advertise from the master-server */ -void NetworkUDPRemoveAdvertise(void) +void NetworkUDPRemoveAdvertise() { struct sockaddr_in out_addr; @@ -533,7 +533,7 @@ void NetworkUDPRemoveAdvertise(void) /* Register us to the master server This function checks if it needs to send an advertise */ -void NetworkUDPAdvertise(void) +void NetworkUDPAdvertise() { struct sockaddr_in out_addr; @@ -580,7 +580,7 @@ void NetworkUDPAdvertise(void) _udp_master_socket->SendPacket(&p, &out_addr); } -void NetworkUDPInitialize(void) +void NetworkUDPInitialize() { _udp_client_socket = new ClientNetworkUDPSocketHandler(); _udp_server_socket = new ServerNetworkUDPSocketHandler(); @@ -590,7 +590,7 @@ void NetworkUDPInitialize(void) _network_udp_broadcast = 0; } -void NetworkUDPShutdown(void) +void NetworkUDPShutdown() { NetworkUDPCloseAll(); diff --git a/src/network/network_udp.h b/src/network/network_udp.h index ed9f5b952..f62f3c016 100644 --- a/src/network/network_udp.h +++ b/src/network/network_udp.h @@ -5,13 +5,13 @@ #ifdef ENABLE_NETWORK -void NetworkUDPInitialize(void); -void NetworkUDPSearchGame(void); -void NetworkUDPQueryMasterServer(void); +void NetworkUDPInitialize(); +void NetworkUDPSearchGame(); +void NetworkUDPQueryMasterServer(); void NetworkUDPQueryServer(const char* host, unsigned short port, bool manually = false); -void NetworkUDPAdvertise(void); -void NetworkUDPRemoveAdvertise(void); -void NetworkUDPShutdown(void); +void NetworkUDPAdvertise(); +void NetworkUDPRemoveAdvertise(); +void NetworkUDPShutdown(); #endif /* ENABLE_NETWORK */ |