mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-11 12:25:53 +00:00
Bug #154348. Clipboard hangs when pasting to another application. Don't double free a string. Not part of the build.
This commit is contained in:
parent
ad83be3643
commit
3de4689a0d
@ -449,15 +449,12 @@ nsClipboard::SelectionGetEvent (GtkWidget *aWidget,
|
||||
nsString ucs2string;
|
||||
ucs2string.Adopt(tmpString);
|
||||
char *utf8string = ToNewUTF8String(ucs2string);
|
||||
if (!utf8string) {
|
||||
nsMemory::Free(tmpString);
|
||||
if (!utf8string)
|
||||
return;
|
||||
}
|
||||
|
||||
gtk_selection_data_set_text (aSelectionData, utf8string,
|
||||
strlen(utf8string));
|
||||
|
||||
nsMemory::Free(tmpString);
|
||||
nsMemory::Free(utf8string);
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user