Repository: logging-log4cxx
Updated Branches:
  refs/heads/logcxx_369 818be2527 -> e6c8f59f7


mbsrtowcs() returns the number of wide char,but not the source in string length.

If there have n chinese characters,the log will output more last n characters.


Project: http://git-wip-us.apache.org/repos/asf/logging-log4cxx/repo
Commit: http://git-wip-us.apache.org/repos/asf/logging-log4cxx/commit/71e9a3fc
Tree: http://git-wip-us.apache.org/repos/asf/logging-log4cxx/tree/71e9a3fc
Diff: http://git-wip-us.apache.org/repos/asf/logging-log4cxx/diff/71e9a3fc

Branch: refs/heads/logcxx_369
Commit: 71e9a3fc21f4abdab4b5e2beecd0ae3ac1ee25da
Parents: 818be25
Author: wzf <[email protected]>
Authored: Wed Mar 21 14:34:41 2018 +0800
Committer: Thorsten Schöning <[email protected]>
Committed: Wed Mar 21 13:52:57 2018 +0100

----------------------------------------------------------------------
 src/main/cpp/charsetdecoder.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/logging-log4cxx/blob/71e9a3fc/src/main/cpp/charsetdecoder.cpp
----------------------------------------------------------------------
diff --git a/src/main/cpp/charsetdecoder.cpp b/src/main/cpp/charsetdecoder.cpp
index d288725..aa5a6a0 100644
--- a/src/main/cpp/charsetdecoder.cpp
+++ b/src/main/cpp/charsetdecoder.cpp
@@ -177,7 +177,7 @@ namespace log4cxx
                                break;
                            } else {
                                stat = append(out, buf);
-                               in.position(in.position() + converted);
+                               in.position(in.position() + requested);
                            }
                       }
                   }

Reply via email to