diff options
author | Mike Buland <eichlan@xagasoft.com> | 2006-05-04 08:32:59 +0000 |
---|---|---|
committer | Mike Buland <eichlan@xagasoft.com> | 2006-05-04 08:32:59 +0000 |
commit | 45b0d6d941c95ab28a143b6a78ac5c2d99b6bc4f (patch) | |
tree | 5c945401052f63252dd47b170272c0cf65fba467 | |
parent | 5c30c56085b267796f2bc56690e2beaf8f9557a4 (diff) | |
download | libbu++-45b0d6d941c95ab28a143b6a78ac5c2d99b6bc4f.tar.gz libbu++-45b0d6d941c95ab28a143b6a78ac5c2d99b6bc4f.tar.bz2 libbu++-45b0d6d941c95ab28a143b6a78ac5c2d99b6bc4f.tar.xz libbu++-45b0d6d941c95ab28a143b6a78ac5c2d99b6bc4f.zip |
Removed some extra test functions that were interfering with some other
programs. Also disabled auto-log rotation until I can come up with a better
way of doing it.
-rw-r--r-- | src/multilog.cpp | 5 | ||||
-rw-r--r-- | src/multilogtext.cpp | 8 | ||||
-rw-r--r-- | src/test/log.cpp | 4 |
3 files changed, 4 insertions, 13 deletions
diff --git a/src/multilog.cpp b/src/multilog.cpp index 3dfb8b6..143ee89 100644 --- a/src/multilog.cpp +++ b/src/multilog.cpp | |||
@@ -6,11 +6,6 @@ | |||
6 | 6 | ||
7 | #include "multilogchannel.h" | 7 | #include "multilogchannel.h" |
8 | 8 | ||
9 | void testlog( const char *text ) | ||
10 | { | ||
11 | MultiLineLog( 4, text ); | ||
12 | } | ||
13 | |||
14 | MultiLog::MultiLog() | 9 | MultiLog::MultiLog() |
15 | { | 10 | { |
16 | lChannel = new LinkedList(); | 11 | lChannel = new LinkedList(); |
diff --git a/src/multilogtext.cpp b/src/multilogtext.cpp index daad4c0..4337cc9 100644 --- a/src/multilogtext.cpp +++ b/src/multilogtext.cpp | |||
@@ -5,7 +5,7 @@ | |||
5 | #include <time.h> | 5 | #include <time.h> |
6 | #include <string.h> | 6 | #include <string.h> |
7 | #include "multilogtext.h" | 7 | #include "multilogtext.h" |
8 | 8 | /* | |
9 | bool fileexists( const char *sPath ) | 9 | bool fileexists( const char *sPath ) |
10 | { | 10 | { |
11 | int nFileDesc = open( sPath, O_RDONLY ); | 11 | int nFileDesc = open( sPath, O_RDONLY ); |
@@ -18,12 +18,12 @@ bool fileexists( const char *sPath ) | |||
18 | close( nFileDesc ); | 18 | close( nFileDesc ); |
19 | return true; | 19 | return true; |
20 | } | 20 | } |
21 | } | 21 | }*/ |
22 | 22 | ||
23 | MultiLogText::MultiLogText( const char *sFileName, const char *lpFormat, bool bRotateLog, int nMaxLogs ) | 23 | MultiLogText::MultiLogText( const char *sFileName, const char *lpFormat, bool bRotateLog, int nMaxLogs ) |
24 | { | 24 | { |
25 | this->lpFormat = NULL; | 25 | this->lpFormat = NULL; |
26 | 26 | /* | |
27 | if( bRotateLog ) | 27 | if( bRotateLog ) |
28 | { | 28 | { |
29 | if( fileexists( sFileName ) == false ) | 29 | if( fileexists( sFileName ) == false ) |
@@ -44,7 +44,7 @@ MultiLogText::MultiLogText( const char *sFileName, const char *lpFormat, bool bR | |||
44 | break; | 44 | break; |
45 | } | 45 | } |
46 | } | 46 | } |
47 | } | 47 | }*/ |
48 | 48 | ||
49 | nFD = open( sFileName, O_WRONLY|O_CREAT|O_TRUNC, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH ); | 49 | nFD = open( sFileName, O_WRONLY|O_CREAT|O_TRUNC, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH ); |
50 | setLogFormat( lpFormat ); | 50 | setLogFormat( lpFormat ); |
diff --git a/src/test/log.cpp b/src/test/log.cpp index 0420e37..d7cfa0b 100644 --- a/src/test/log.cpp +++ b/src/test/log.cpp | |||
@@ -4,8 +4,6 @@ | |||
4 | #include "multilog.h" | 4 | #include "multilog.h" |
5 | #include "multilogtext.h" | 5 | #include "multilogtext.h" |
6 | 6 | ||
7 | void testlog( const char *text ); | ||
8 | |||
9 | class Test | 7 | class Test |
10 | { | 8 | { |
11 | public: | 9 | public: |
@@ -27,7 +25,5 @@ int main() | |||
27 | 25 | ||
28 | MultiLineLog( MultiLog::LError, "Hi there!"); | 26 | MultiLineLog( MultiLog::LError, "Hi there!"); |
29 | Test t; | 27 | Test t; |
30 | |||
31 | testlog("external test"); | ||
32 | } | 28 | } |
33 | 29 | ||