Fix library sync crash due to exotic playlist characters

- Fixes #523
This commit is contained in:
croneter 2018-08-07 18:11:23 +02:00
parent bccd79da38
commit 3fd40b64c6

View file

@ -115,7 +115,7 @@ def _write_playlist_to_file(playlist, xml):
text += ('#EXTINF:%s,%s\n%s\n'
% (api.runtime(), api.title(), api.path()))
text += '\n'
text = text.encode(v.M3U_ENCODING, 'strict')
text = text.encode(v.M3U_ENCODING, 'ignore')
try:
with open(path_ops.encode_path(playlist.kodi_path), 'wb') as f:
f.write(text)