- commit
- 427d698da984a660850d3fbdf9d34fbc10fe05c8
- parent
- 70f244ef8f59066cdbadd133c40aa4dc1f4d04cc
- Author
- Tobias Bengfort <tobias.bengfort@posteo.de>
- Date
- 2022-12-05 17:59
do not crash on invalid utf-8 from mpv see https://mpv.io/manual/master/#utf-8
Diffstat
| M | cplay.py | 2 | +- |
1 files changed, 1 insertions, 1 deletions
diff --git a/cplay.py b/cplay.py
@@ -189,7 +189,7 @@ class Player: 189 189 msgs = self._buffer.split(b'\n') 190 190 self._buffer = msgs.pop() 191 191 for msg in msgs:192 -1 data = json.loads(msg.decode('utf-8'))-1 192 data = json.loads(msg.decode('utf-8', errors='replace')) 193 193 self.handle_ipc(data) 194 194 195 195 def get_progress(self):