From 1f0d6faf149e4fa8bda65a57bfb3fdeb6b9f5947 Mon Sep 17 00:00:00 2001 From: "Martijn van Berkel (Flitskikker)" Date: Sat, 15 Jul 2023 14:01:07 +0200 Subject: [PATCH] Copy ShotChangeHelper fix --- src/libse/Common/TimeCodesFileHelper.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/libse/Common/TimeCodesFileHelper.cs b/src/libse/Common/TimeCodesFileHelper.cs index 47bcde766..33b630227 100644 --- a/src/libse/Common/TimeCodesFileHelper.cs +++ b/src/libse/Common/TimeCodesFileHelper.cs @@ -28,6 +28,12 @@ namespace Nikse.SubtitleEdit.Core.Common public static List FromDisk(string videoFileName) { var list = new List(); + + if (string.IsNullOrEmpty(videoFileName)) + { + return list; + } + var timeCodesFileName = GetTimeCodesFileName(videoFileName); if (!File.Exists(timeCodesFileName)) { @@ -41,6 +47,7 @@ namespace Nikse.SubtitleEdit.Core.Common list.Add(double.Parse(line, CultureInfo.InvariantCulture)); } } + return list; }