mirror of https://github.com/odrling/Aegisub
Work around bug #772, v1 timecodes files with overlapping or out of order ranges caused weird behaviour. Now those files are simply rejected.
Originally committed to SVN as r2339.
This commit is contained in:
parent
a631b76684
commit
d92efd1f54
|
@ -151,6 +151,9 @@ void FrameRate::Load(wxString filename) {
|
|||
if (!temp.ToDouble(&lfps) || lfps <= 0)
|
||||
throw _T("Timecode parsing error, invalid fps format found");
|
||||
|
||||
if (lstart <= lposition)
|
||||
throw _T("Timecode parsing error, out of order or overlapping timecode range found");
|
||||
|
||||
|
||||
for (int i = 0; i <= lstart - lposition - 2; i++)
|
||||
AddFrame((int)(floor(currenttime+(i*1000) / AverageFrameRate)));
|
||||
|
|
Loading…
Reference in New Issue