From b337fbd691687b0e635a42aaf1ec2e139b6cd62b Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Fri, 11 Jan 2013 08:30:33 -0800 Subject: [PATCH] Fix loading unicode actor names from plain text files 'isComment ? "" : actor' results in actor decaying to a const char * in the local charset rather than converting "" to wxString, which breaks things when unicode is involved. --- aegisub/src/subtitle_format_txt.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aegisub/src/subtitle_format_txt.cpp b/aegisub/src/subtitle_format_txt.cpp index 8d0cce74a..8f6f98b19 100644 --- a/aegisub/src/subtitle_format_txt.cpp +++ b/aegisub/src/subtitle_format_txt.cpp @@ -117,7 +117,7 @@ void TXTSubtitleFormat::ReadFile(AssFile *target, wxString const& filename, wxSt // Sets line up AssDialogue *line = new AssDialogue; - line->Actor = isComment ? "" : actor; + line->Actor = isComment ? wxEmptyString : actor; line->Comment = isComment; line->Text = value; line->End = 0;