Author: carnold
Date: Fri Feb 15 02:03:52 2008
New Revision: 627988

URL: http://svn.apache.org/viewvc?rev=627988&view=rev
Log:
LOGCXX-241: VC6 pass

Modified:
    logging/log4cxx/trunk/src/main/cpp/file.cpp
    logging/log4cxx/trunk/src/main/cpp/gzcompressaction.cpp
    logging/log4cxx/trunk/src/main/cpp/zipcompressaction.cpp
    logging/log4cxx/trunk/src/test/cpp/util/transformer.cpp
    logging/log4cxx/trunk/src/test/cpp/xml/domtestcase.cpp

Modified: logging/log4cxx/trunk/src/main/cpp/file.cpp
URL: 
http://svn.apache.org/viewvc/logging/log4cxx/trunk/src/main/cpp/file.cpp?rev=627988&r1=627987&r2=627988&view=diff
==============================================================================
--- logging/log4cxx/trunk/src/main/cpp/file.cpp (original)
+++ logging/log4cxx/trunk/src/main/cpp/file.cpp Fri Feb 15 02:03:52 2008
@@ -204,9 +204,9 @@
             if (entry.name != NULL) {
                LogString filename;
                if(style == APR_FILEPATH_ENCODING_UTF8) {
-                  Transcoder::encodeUTF8(entry.name, filename);
+                          Transcoder::decodeUTF8(entry.name, filename);
                } else {
-                   Transcoder::encode(entry.name, filename);
+                   Transcoder::decode(entry.name, filename);
                }
                filenames.push_back(filename);
             }

Modified: logging/log4cxx/trunk/src/main/cpp/gzcompressaction.cpp
URL: 
http://svn.apache.org/viewvc/logging/log4cxx/trunk/src/main/cpp/gzcompressaction.cpp?rev=627988&r1=627987&r2=627988&view=diff
==============================================================================
--- logging/log4cxx/trunk/src/main/cpp/gzcompressaction.cpp (original)
+++ logging/log4cxx/trunk/src/main/cpp/gzcompressaction.cpp Fri Feb 15 02:03:52 
2008
@@ -18,7 +18,8 @@
 #include <log4cxx/rolling/gzcompressaction.h>
 #include <apr_thread_proc.h>
 #include <apr_strings.h>
-#include <log4cxx/helpers/exception.h>
+#include <log4cxx/helpers/exception.h>
+#include <log4cxx/helpers/transcoder.h>
 
 using namespace log4cxx;
 using namespace log4cxx::rolling;

Modified: logging/log4cxx/trunk/src/main/cpp/zipcompressaction.cpp
URL: 
http://svn.apache.org/viewvc/logging/log4cxx/trunk/src/main/cpp/zipcompressaction.cpp?rev=627988&r1=627987&r2=627988&view=diff
==============================================================================
--- logging/log4cxx/trunk/src/main/cpp/zipcompressaction.cpp (original)
+++ logging/log4cxx/trunk/src/main/cpp/zipcompressaction.cpp Fri Feb 15 
02:03:52 2008
@@ -18,7 +18,8 @@
 #include <log4cxx/rolling/zipcompressaction.h>
 #include <apr_thread_proc.h>
 #include <apr_strings.h>
-#include <log4cxx/helpers/exception.h>
+#include <log4cxx/helpers/exception.h>
+#include <log4cxx/helpers/transcoder.h>
 
 using namespace log4cxx;
 using namespace log4cxx::rolling;

Modified: logging/log4cxx/trunk/src/test/cpp/util/transformer.cpp
URL: 
http://svn.apache.org/viewvc/logging/log4cxx/trunk/src/test/cpp/util/transformer.cpp?rev=627988&r1=627987&r2=627988&view=diff
==============================================================================
--- logging/log4cxx/trunk/src/test/cpp/util/transformer.cpp (original)
+++ logging/log4cxx/trunk/src/test/cpp/util/transformer.cpp Fri Feb 15 02:03:52 
2008
@@ -17,6 +17,7 @@
 
 #include "transformer.h"
 #include <log4cxx/file.h>
+#include <log4cxx/helpers/transcoder.h>
 #include <apr_thread_proc.h>
 #include <apr_pools.h>
 #include <apr_file_io.h>

Modified: logging/log4cxx/trunk/src/test/cpp/xml/domtestcase.cpp
URL: 
http://svn.apache.org/viewvc/logging/log4cxx/trunk/src/test/cpp/xml/domtestcase.cpp?rev=627988&r1=627987&r2=627988&view=diff
==============================================================================
--- logging/log4cxx/trunk/src/test/cpp/xml/domtestcase.cpp (original)
+++ logging/log4cxx/trunk/src/test/cpp/xml/domtestcase.cpp Fri Feb 15 02:03:52 
2008
@@ -190,12 +190,10 @@
                 
DOMConfigurator::configure(LOG4CXX_TEST_STR("input/xml/DOMTestCase3.xml"));
                 LOG4CXX_INFO(logger, "File name is expected to end with a 
superscript 3");
 #if LOG4CXX_LOGCHAR_IS_UTF8
-                const logchar end[] = { 0xC2, 0xB3, 0 };
+                const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 
0x2F, 0x64, 0x6F, 0x6D, 0xC2, 0xB3, 0 };
 #else
-                const logchar end[] = { 0xB3, 0 };
+                const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 
0x2F, 0x64, 0x6F, 0x6D, 0xB3, 0 };
 #endif
-                LogString fname("output/dom");
-                fname.append(end);
                 File file;
                 file.setPath(fname);
                 Pool p;
@@ -204,19 +202,17 @@
         }
 
         /**
-         *   Creates a output file that ends with a superscript 3.
+         *   Creates a output file that ends with a ideographic 4.
          *   Output file is checked by build.xml after completion.
          */  
         void test4() {
                 
DOMConfigurator::configure(LOG4CXX_TEST_STR("input/xml/DOMTestCase4.xml"));
                 LOG4CXX_INFO(logger, "File name is expected to end with an 
ideographic 4");
 #if LOG4CXX_LOGCHAR_IS_UTF8
-                const logchar end[] = { 0xE3, 0x86, 0x95, 0 };
+                const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 
0x2F, 0x64, 0x6F, 0x6D, 0xE3, 0x86, 0x95, 0 };
 #else
-                const logchar end[] = { 0x3195, 0 };
+                const logchar fname[] = { 0x6F, 0x75, 0x74, 0x70, 0x75, 0x74, 
0x2F, 0x64, 0x6F, 0x6D, 0x3195, 0 };
 #endif
-                LogString fname("output/dom");
-                fname.append(end);
                 File file;
                 file.setPath(fname);
                 Pool p;


Reply via email to