From 317fba2e1e7a1fcf7b473679ecc179a64a0ab2d4 Mon Sep 17 00:00:00 2001 From: Dan Donovan Date: Tue, 6 Feb 2007 22:35:15 +0000 Subject: [PATCH] Trim raw data from left before parsing a style, else the mid(6) to get rid of "style:" can fail, usually leaving the : Originally committed to SVN as r927. --- aegisub/ass_style.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aegisub/ass_style.cpp b/aegisub/ass_style.cpp index c505d3366..0a45b3dc7 100644 --- a/aegisub/ass_style.cpp +++ b/aegisub/ass_style.cpp @@ -197,7 +197,7 @@ bool AssStyle::Parse(wxString rawData,int version) { // Tokenize wxString temp; long templ; - wxStringTokenizer tkn(rawData.Mid(6),_T(","),wxTOKEN_RET_EMPTY_ALL); + wxStringTokenizer tkn(rawData.Trim(false).Mid(6),_T(","),wxTOKEN_RET_EMPTY_ALL); // Read name if (!tkn.HasMoreTokens()) return false;