summaryrefslogtreecommitdiff
path: root/core/io/logger.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/io/logger.cpp')
-rw-r--r--core/io/logger.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/core/io/logger.cpp b/core/io/logger.cpp
index 01755c8ee9..3c4b4a1ac3 100644
--- a/core/io/logger.cpp
+++ b/core/io/logger.cpp
@@ -179,11 +179,10 @@ void RotatedFileLogger::rotate_file() {
file = FileAccess::open(base_path, FileAccess::WRITE);
}
-RotatedFileLogger::RotatedFileLogger(const String &p_base_path, int p_max_files) {
- file = NULL;
- base_path = p_base_path.simplify_path();
- max_files = p_max_files > 0 ? p_max_files : 1;
-
+RotatedFileLogger::RotatedFileLogger(const String &p_base_path, int p_max_files) :
+ base_path(p_base_path.simplify_path()),
+ max_files(p_max_files > 0 ? p_max_files : 1),
+ file(NULL) {
rotate_file();
}
@@ -240,8 +239,8 @@ void StdLogger::logv(const char *p_format, va_list p_list, bool p_err) {
StdLogger::~StdLogger() {}
-CompositeLogger::CompositeLogger(Vector<Logger *> p_loggers) {
- loggers = p_loggers;
+CompositeLogger::CompositeLogger(Vector<Logger *> p_loggers) :
+ loggers(p_loggers) {
}
void CompositeLogger::logv(const char *p_format, va_list p_list, bool p_err) {