summaryrefslogtreecommitdiff
path: root/src/log.h
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2005-04-01 00:14:51 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2005-04-01 00:14:51 +0000
commit05f71c98af1bc9d9aabf3e8e3dc78cae75675e1c (patch)
tree921b18da0dc52e7562f0c6a02e5343f9b582cf64 /src/log.h
parent78c72d1463735ad6e3a176f89d3c41a5ed71fc40 (diff)
downloadmana-client-05f71c98af1bc9d9aabf3e8e3dc78cae75675e1c.tar.gz
mana-client-05f71c98af1bc9d9aabf3e8e3dc78cae75675e1c.tar.bz2
mana-client-05f71c98af1bc9d9aabf3e8e3dc78cae75675e1c.tar.xz
mana-client-05f71c98af1bc9d9aabf3e8e3dc78cae75675e1c.zip
* The client will now only attempt to load .tmx or .tmx.gz files.
* When unable to connect to char server, report IP to which it can't connect. * Cleaned up logger a bit.
Diffstat (limited to 'src/log.h')
-rw-r--r--src/log.h53
1 files changed, 24 insertions, 29 deletions
diff --git a/src/log.h b/src/log.h
index 64da662b..d73f4c99 100644
--- a/src/log.h
+++ b/src/log.h
@@ -23,7 +23,6 @@
#define _LOG_H
#include <stdlib.h>
-#include <stdio.h>
#include <stdarg.h>
#include <time.h>
#include <string>
@@ -35,34 +34,30 @@
*/
class Logger
{
-public:
-
-/**
- * Constructor :
- * Initializes log file by opening it for writing.
- */
-Logger(std::string logFilename);
-
-/**
- * Destructor
- */
-~Logger();
-
-/**
- * Enters a message in the log. The message will be timestamped.
- */
-void log(const char *log_text, ...);
-
-/**
- * Log an error and quit. The error will pop-up in Windows and will be printed
- * to standard error everywhere else.
- */
-void error(const std::string &error_text);
-
-private:
-
-std::ofstream logFile;
-
+ public:
+ /**
+ * Constructor, opens log file for writing.
+ */
+ Logger(const std::string &logFilename);
+
+ /**
+ * Destructor, closes log file.
+ */
+ ~Logger();
+
+ /**
+ * Enters a message in the log. The message will be timestamped.
+ */
+ void log(const char *log_text, ...);
+
+ /**
+ * Log an error and quit. The error will pop-up in Windows and will be
+ * printed to standard error everywhere else.
+ */
+ void error(const std::string &error_text);
+
+ private:
+ std::ofstream logFile;
};
#endif