fixes for win32 clipboard due to CUnicode nul terminator changes.
This commit is contained in:
parent
a150f64e9c
commit
2e6e8e179a
|
@ -33,7 +33,7 @@ CMSWindowsClipboardTextConverter::doToIClipboard(const CString& data) const
|
|||
{
|
||||
// convert and strip nul terminator
|
||||
CString dst = CUnicode::textToUTF8(data);
|
||||
if (dst.size() > 0 && dst[size() - 1] == '\0') {
|
||||
if (dst.size() > 0 && dst[dst.size() - 1] == '\0') {
|
||||
dst.erase(dst.size() - 1);
|
||||
}
|
||||
return dst;
|
||||
|
|
|
@ -33,7 +33,7 @@ CMSWindowsClipboardUTF16Converter::doToIClipboard(const CString& data) const
|
|||
{
|
||||
// convert and strip nul terminator
|
||||
CString dst = CUnicode::UTF16ToUTF8(data);
|
||||
if (dst.size() > 0 && dst[size() - 1] == '\0') {
|
||||
if (dst.size() > 0 && dst[dst.size() - 1] == '\0') {
|
||||
dst.erase(dst.size() - 1);
|
||||
}
|
||||
return dst;
|
||||
|
|
Loading…
Reference in New Issue