diff options
author | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-09-14 12:35:45 +0000 |
---|---|---|
committer | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-09-14 12:35:45 +0000 |
commit | 760d4498bd6a7a079cbff9b79d4dfcdde2e4665e (patch) | |
tree | 3349a48f5b1265acf24f35769f170467e2ca2344 /src | |
parent | a8c805e28016af5e6d20228e80a1d4a2f6c02c67 (diff) | |
download | mana-760d4498bd6a7a079cbff9b79d4dfcdde2e4665e.tar.gz mana-760d4498bd6a7a079cbff9b79d4dfcdde2e4665e.tar.bz2 mana-760d4498bd6a7a079cbff9b79d4dfcdde2e4665e.tar.xz mana-760d4498bd6a7a079cbff9b79d4dfcdde2e4665e.zip |
Header cleanups.
Diffstat (limited to 'src')
-rw-r--r-- | src/game.cpp | 1 | ||||
-rw-r--r-- | src/gui/char_select.cpp | 2 | ||||
-rw-r--r-- | src/gui/char_server.cpp | 1 | ||||
-rw-r--r-- | src/gui/login.cpp | 2 | ||||
-rw-r--r-- | src/log.cpp | 2 | ||||
-rw-r--r-- | src/main.cpp | 2 | ||||
-rw-r--r-- | src/net/messageout.cpp | 3 | ||||
-rw-r--r-- | src/net/messageout.h | 4 | ||||
-rw-r--r-- | src/net/network.cpp | 16 | ||||
-rw-r--r-- | src/net/network.h | 6 | ||||
-rw-r--r-- | src/net/packet.cpp | 4 | ||||
-rw-r--r-- | src/net/protocol.cpp | 1 |
12 files changed, 24 insertions, 20 deletions
diff --git a/src/game.cpp b/src/game.cpp index 2fb79ef7..3729ee48 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -61,6 +61,7 @@ #include "gui/status.h" #include "gui/trade.h" +#include "net/messagein.h" #include "net/network.h" #include "net/protocol.h" diff --git a/src/gui/char_select.cpp b/src/gui/char_select.cpp index 862e659d..e86c5d5a 100644 --- a/src/gui/char_select.cpp +++ b/src/gui/char_select.cpp @@ -39,6 +39,8 @@ #include "../log.h" #include "../main.h" #include "../playerinfo.h" + +#include "../net/messagein.h" #include "../net/network.h" #include "../net/protocol.h" diff --git a/src/gui/char_server.cpp b/src/gui/char_server.cpp index d3abfe7c..79269a2e 100644 --- a/src/gui/char_server.cpp +++ b/src/gui/char_server.cpp @@ -36,6 +36,7 @@ #include "../playerinfo.h" #include "../serverinfo.h" +#include "../net/messagein.h" #include "../net/network.h" extern SERVER_INFO **server_info; diff --git a/src/gui/login.cpp b/src/gui/login.cpp index bc39c15f..bb762843 100644 --- a/src/gui/login.cpp +++ b/src/gui/login.cpp @@ -41,6 +41,8 @@ #include "textfield.h" #include "ok_dialog.h" +#include "../net/messagein.h" +#include "../net/messageout.h" #include "../net/network.h" OkDialog *wrongLoginNotice = NULL; diff --git a/src/log.cpp b/src/log.cpp index 65519cba..78db9eff 100644 --- a/src/log.cpp +++ b/src/log.cpp @@ -27,7 +27,7 @@ #include <Carbon/Carbon.h> #endif -#include <stdarg.h> +#include <cstdarg> #include <iostream> #include <sstream> diff --git a/src/main.cpp b/src/main.cpp index 4da837c8..c176819a 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -34,7 +34,7 @@ #include <libxml/parser.h> #ifdef __USE_UNIX98 -#include <errno.h> +#include <cerrno> #include <sys/stat.h> #endif diff --git a/src/net/messageout.cpp b/src/net/messageout.cpp index 871ba43a..272cac4e 100644 --- a/src/net/messageout.cpp +++ b/src/net/messageout.cpp @@ -23,10 +23,11 @@ #include "messageout.h" -#include <iostream> +#include <string> #include <SDL_net.h> #include "network.h" +#include "packet.h" MessageOut::MessageOut(): mPacket(0), diff --git a/src/net/messageout.h b/src/net/messageout.h index d836b43f..7cbca165 100644 --- a/src/net/messageout.h +++ b/src/net/messageout.h @@ -24,9 +24,9 @@ #ifndef _TMW_MESSAGEOUT_ #define _TMW_MESSAGEOUT_ -#include <string> +#include <iosfwd> -#include "packet.h" +class Packet; /** * Used for building an outgoing message. diff --git a/src/net/network.cpp b/src/net/network.cpp index 6624ee1e..3b1d6569 100644 --- a/src/net/network.cpp +++ b/src/net/network.cpp @@ -21,18 +21,18 @@ * $Id$ */ -#include "../log.h" #include "network.h" -#include "protocol.h" + +#include <cassert> +#include <sstream> +#include <SDL_net.h> + +#include "messagein.h" + +#include "../log.h" #ifdef MACOSX #include "win2mac.h" #endif -#ifndef WIN32 -#include <unistd.h> -#include <fcntl.h> -#include <errno.h> -#endif -#include <sstream> /** Warning: buffers and other variables are shared, so there can be only one connection active at a time */ diff --git a/src/net/network.h b/src/net/network.h index a037c6fa..b6c4a520 100644 --- a/src/net/network.h +++ b/src/net/network.h @@ -24,11 +24,7 @@ #ifndef _TMW_NETWORK_ #define _TMW_NETWORK_ -#include <string> - -#include "SDL_net.h" -#include "messagein.h" -#include "messageout.h" +class MessageIn; /** Convert an address from int format to string */ char *iptostring(int address); diff --git a/src/net/packet.cpp b/src/net/packet.cpp index b8ee1e7f..6d7b2b3e 100644 --- a/src/net/packet.cpp +++ b/src/net/packet.cpp @@ -22,8 +22,8 @@ */ #include "packet.h" -#include <string.h> -#include <cstdlib> + +#include <cstring> Packet::Packet(const char *data, int length): length(length) diff --git a/src/net/protocol.cpp b/src/net/protocol.cpp index 17076b90..5a1ed9c5 100644 --- a/src/net/protocol.cpp +++ b/src/net/protocol.cpp @@ -23,6 +23,7 @@ #include "protocol.h" +#include "messagein.h" #include "network.h" #include "../being.h" |