• R/O
  • SSH
  • HTTPS

tortoisesvn: 提交


Commit MetaInfo

修订版28753 (tree)
时间2020-02-22 03:36:24
作者stefankueng

Log Message

Fix off-by-one error.

更改概述

差异

--- trunk/src/Utils/UnicodeUtils.cpp (revision 28752)
+++ trunk/src/Utils/UnicodeUtils.cpp (revision 28753)
@@ -1,6 +1,6 @@
11 // TortoiseSVN - a Windows shell extension for easy version control
22
3-// Copyright (C) 2003-2006, 2008-2013, 2015 - TortoiseSVN
3+// Copyright (C) 2003-2006, 2008-2013, 2015, 2020 - TortoiseSVN
44 // Copyright (C) 2020 - TortoiseGit
55
66 // This program is free software; you can redistribute it and/or
@@ -123,7 +123,7 @@
123123 int len = WideCharToMultiByte(CP_UTF8, 0, wide.c_str(), size, buffer, 4*size, 0, NULL);
124124 if (len == 0)
125125 return std::string();
126- return std::string (buffer, len-1);
126+ return std::string (buffer, len);
127127 }
128128
129129 std::wstring CUnicodeUtils::StdGetUnicode(const std::string& utf8)
Show on old repository browser