1
0
mirror of https://github.com/odrling/Aegisub synced 2025-04-11 22:56:02 +02:00

Actually initialize the initial MatchState in the search replace engine

This commit is contained in:
Thomas Goyne 2014-05-05 18:52:16 -07:00
parent a00e5dc967
commit ca86b0da33

View File

@ -231,7 +231,7 @@ bool SearchReplaceEngine::FindReplace(bool replace) {
auto it = context->ass->iterator_to(*line);
size_t pos = 0;
MatchState replace_ms;
MatchState replace_ms{nullptr, 0, -1};
if (replace) {
if (settings.field == SearchReplaceSettings::Field::TEXT)
pos = context->textSelectionController->GetSelectionStart();