carnold 2005/01/05 23:26:56
Modified: src ndc.cpp relativetimedateformat.cpp stringhelper.cpp
telnetappender.cpp
tests/src main.cpp streamtestcase.cpp
Log:
x86_64 compilation fixes
Revision Changes Path
1.13 +15 -15 logging-log4cxx/src/ndc.cpp
Index: ndc.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/src/ndc.cpp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- ndc.cpp 5 Jan 2005 22:42:58 -0000 1.12
+++ ndc.cpp 6 Jan 2005 07:26:56 -0000 1.13
@@ -43,7 +43,7 @@
const DiagnosticContext& src)
{
message.assign(src.message);
- fullMessage.assign(src.fullMessage);
+ fullMessage.assign(src.fullMessage);
return *this;
}
@@ -158,17 +158,17 @@
clear();
}
-bool NDC::empty() {
- Stack& stack = ThreadSpecificData::getCurrentThreadStack();
- return stack.empty();
-}
-
-bool NDC::isNull(const LogString& str) {
- return str == getNull();
-}
-
-
-const LogString& NDC::getNull() {
- static LogString nullStr(LOG4CXX_STR("null"));
- return nullStr;
-}
\ No newline at end of file
+bool NDC::empty() {
+ Stack& stack = ThreadSpecificData::getCurrentThreadStack();
+ return stack.empty();
+}
+
+bool NDC::isNull(const LogString& str) {
+ return str == getNull();
+}
+
+
+const LogString& NDC::getNull() {
+ static LogString nullStr(LOG4CXX_STR("null"));
+ return nullStr;
+}
1.9 +1 -1 logging-log4cxx/src/relativetimedateformat.cpp
Index: relativetimedateformat.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/src/relativetimedateformat.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- relativetimedateformat.cpp 3 Jan 2005 06:43:44 -0000 1.8
+++ relativetimedateformat.cpp 6 Jan 2005 07:26:56 -0000 1.9
@@ -37,6 +37,6 @@
LogString &s,
log4cxx_time_t date,
Pool& p) const {
- apr_int64_t interval = (date - startTime) / APR_INT64_C(1000);
+ log4cxx_int64_t interval = (date - startTime) / APR_INT64_C(1000);
s.append(StringHelper::toString(interval, p));
}
1.11 +3 -3 logging-log4cxx/src/stringhelper.cpp
Index: stringhelper.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/src/stringhelper.cpp,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- stringhelper.cpp 3 Jan 2005 06:43:44 -0000 1.10
+++ stringhelper.cpp 6 Jan 2005 07:26:56 -0000 1.11
@@ -234,15 +234,15 @@
}
LogString StringHelper::toString(size_t n, Pool& pool) {
- return toString((apr_int64_t) n, pool);
+ return toString((log4cxx_int64_t) n, pool);
}
void StringHelper::toString(size_t n, Pool& pool, std::string& s) {
- toString((apr_int64_t) n, pool, s);
+ toString((log4cxx_int64_t) n, pool, s);
}
void StringHelper::toString(size_t n, Pool& pool, std::wstring& ws) {
- toString((apr_int64_t) n, pool, ws);
+ toString((log4cxx_int64_t) n, pool, ws);
}
1.15 +1 -1 logging-log4cxx/src/telnetappender.cpp
Index: telnetappender.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/src/telnetappender.cpp,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- telnetappender.cpp 26 Dec 2004 07:31:53 -0000 1.14
+++ telnetappender.cpp 6 Jan 2005 07:26:56 -0000 1.15
@@ -162,7 +162,7 @@
newClient->close();
} else {
LogString oss(LOG4CXX_STR("TelnetAppender v1.0 ("));
- oss += StringHelper::toString(count, pThis->pool);
+ oss += StringHelper::toString((int) count,
pThis->pool);
oss += LOG4CXX_STR(" active connections)\r\n\r\n");
os->write(oss);
os->flush();
1.12 +1 -3 logging-log4cxx/tests/src/main.cpp
Index: main.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/tests/src/main.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- main.cpp 26 Dec 2004 07:31:54 -0000 1.11
+++ main.cpp 6 Jan 2005 07:26:56 -0000 1.12
@@ -1,5 +1,5 @@
/*
- * Copyright 2003,2004 The Apache Software Foundation.
+ * Copyright 2003-2005 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -27,13 +27,11 @@
#include <cppunit/CompilerOutputter.h>
#include <cppunit/extensions/TestFactoryRegistry.h>
#include <cppunit/ui/text/TestRunner.h>
-#include <cppunit/BriefTestProgressListener.h>
#include <cppunit/TestSuite.h>
#include <cppunit/TextTestResult.h>
#include <cppunit/TextOutputter.h>
#include <cppunit/TextTestProgressListener.h>
#include <cppunit/TestResult.h>
-#include <cppunit/ui/text/TextTestRunner.h>
#include <iostream>
#include <stdexcept>
#include <log4cxx/basicconfigurator.h>
1.6 +2 -2 logging-log4cxx/tests/src/streamtestcase.cpp
Index: streamtestcase.cpp
===================================================================
RCS file: /home/cvs/logging-log4cxx/tests/src/streamtestcase.cpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- streamtestcase.cpp 3 Jan 2005 23:45:20 -0000 1.5
+++ streamtestcase.cpp 6 Jan 2005 07:26:56 -0000 1.6
@@ -84,8 +84,8 @@
void testConstructor() {
LoggerPtr root(Logger::getRootLogger());
log4cxx::logstream stream(root, log4cxx::Level::INFO);
- CPPUNIT_ASSERT_EQUAL(0, stream.width());
- CPPUNIT_ASSERT_EQUAL(6, stream.precision());
+ CPPUNIT_ASSERT_EQUAL(0, (int) stream.width());
+ CPPUNIT_ASSERT_EQUAL(6, (int) stream.precision());
}
void testSimple() {