From 41cf19288b6eee31c6ded02c5fdb821b093c6b40 Mon Sep 17 00:00:00 2001 From: manongjohn Date: Sat, 3 Apr 2021 18:58:31 -0400 Subject: [PATCH] Fix loading files with multiple dots --- toonz/sources/common/tsystem/tfilepath.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/toonz/sources/common/tsystem/tfilepath.cpp b/toonz/sources/common/tsystem/tfilepath.cpp index d283eb7a..1a76eac3 100644 --- a/toonz/sources/common/tsystem/tfilepath.cpp +++ b/toonz/sources/common/tsystem/tfilepath.cpp @@ -814,8 +814,12 @@ TFilePath TFilePath::withFrame(const TFrameId &frame, int k = str.substr(0, j).rfind(L'.'); bool hasValidFrameNum = false; - if (!isFfmpegType() && checkForSeqNum(type) && isNumbers(str, k, j)) - hasValidFrameNum = true; + if (!isFfmpegType() && checkForSeqNum(type)) { + if (isNumbers(str, k, j)) + hasValidFrameNum = true; + else + k = (int)std::wstring::npos; + } std::string frameString; if (frame.isNoFrame()) frameString = "";