Pass UTF-8 text length for conversion

This commit is contained in:
Chris Young 2012-11-10 16:05:48 +00:00
parent a79e098817
commit 41ed8e3da3

View File

@ -256,9 +256,7 @@ bool gui_add_to_clipboard(const char *text, size_t length, bool space,
if(nsoption_bool(utf8_clipboard)) {
WriteChunkBytes(iffh,text,length);
} else {
buffer = ami_utf8_easy(text);
if(buffer) {
if(utf8_to_local_encoding(text, length, &buffer) == UTF8_CONVERT_OK) {
char *p;
p = buffer;