Skip to content

Commit 3837937

Browse files
committed
bug fixed
1 parent a8c2a7b commit 3837937

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

ASFMKV_dev.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2344,7 +2344,7 @@ def ASFMKV(file: str, outfile: str = '', asslangs: list = [], asspaths: list = [
23442344
return mkvmr
23452345

23462346

2347-
def getFileList(inPath: str, extFilter: list[str] = [], subdir: bool = False) -> list[str]:
2347+
def getFileList(inPath: str, extFilter: list[str] = [], subdir: bool = False) -> list[tuple[str, str]]:
23482348
"""
23492349
从输入的目录中获取文件列表
23502350
需要以下输入
@@ -3659,7 +3659,7 @@ def cFontSubset(font_info):
36593659
if not subonly:
36603660
medias = [[path.splitext(path.basename(cpath))[0], cpath]]
36613661
else:
3662-
subonlyp = [cpath]
3662+
subonlyp = [(path.splitext(path.basename(cpath))[0], cpath)]
36633663
cpath = path.dirname(cpath)
36643664
else:
36653665
if work != 19: medias = getFileList(cpath, extlist, v_subdir)
@@ -3739,6 +3739,7 @@ def cFontSubset(font_info):
37393739
showMessageSubset(newasspaths, newfont_name)
37403740
else:
37413741
break
3742+
if fontload: del font_info2
37423743
else:
37433744
print('\033[1;31m[ERROR] 找不到视频对应字幕\033[0m')
37443745
elif subonly:
@@ -3750,14 +3751,15 @@ def cFontSubset(font_info):
37503751
if work == 19:
37513752
muxer = 2
37523753
for subp in subonlyp:
3753-
newasspaths, newfont_name, mkvr = main(font_info2, [subp],
3754+
newasspaths, newfont_name, mkvr = main(font_info2, [subp[1]],
37543755
mux=False,
37553756
outdir=[assout_cache, fontout_cache, mkvout_cache],
37563757
FFmuxer = muxer)
37573758
if mkvr != -2:
37583759
showMessageSubset(newasspaths, newfont_name)
37593760
else:
37603761
break
3762+
if fontload: del font_info2
37613763

37623764
else:
37633765
leave = False

0 commit comments

Comments
 (0)