Write subtitle names as utf-8 byte stream to stdout
non ascii characters seem to conflict with lua/mpv when writing the filename to stdout, which leads to failure in loading the subtitle. This fixes that.
This commit is contained in:
parent
9c82eea4b3
commit
f480c14de9
|
@ -88,7 +88,7 @@ class subselect :
|
|||
title = video.name + ".srt"
|
||||
s = save_subtitles(video, [subtitle], True, save_dir)
|
||||
if s != [] :
|
||||
print(title, end="")
|
||||
sys.stdout.buffer.write(title.encode("utf-8"))
|
||||
self.root.destroy()
|
||||
else :
|
||||
self.show_message("Download failed", "Subtitle download failed!")
|
||||
|
|
Loading…
Reference in New Issue