[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
BUG: MPV playlist arguments are out-of-date
From: |
acdw |
Subject: |
BUG: MPV playlist arguments are out-of-date |
Date: |
Sat, 29 Jan 2022 00:31:40 +0000 |
User-agent: |
Cyrus-JMAP/3.5.0-alpha0-4585-ga9d9773056-fm-20220113.001-ga9d97730 |
Hello devs and users!
I installed EMMS the other day and was trying to play and set up streaming
playlists. However, they wouldn't play at first. I traced the issue to
`emms-player-mpv-start' in emms-player-mpv.el:
;;...
(if (emms-player-mpv-ipc-fifo-p)
(progn
;; ipc-stop is to clear any buffered commands
(emms-player-mpv-ipc-stop)
(emms-player-mpv-proc-init (if track-is-playlist "--playlist" "--")
;; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
here
track-name)
(emms-player-started emms-player-mpv))
;;...
I'm not sure when, but my version of MPV (0.32.0) doesn't take a plain
--playlist argument; rather it says this about the --playlist argument:
...
--playlist=<filename>
Play files according to a playlist file (Supports some common
formats. If no format is detected, it will be treated as list of
files, separated by newline characters. Note that XML playlist
formats are not supported.)
You can play playlists directly and without this option, how‐
ever, this option disables any security mechanisms that might be
in place. You may also need this option to load plaintext files
as playlist.
WARNING:
The way mpv uses playlist files via --playlist is not safe
against maliciously constructed files. Such files may trigger
harmful actions. This has been the case for all mpv and
MPlayer versions, but unfortunately this fact was not well
documented earlier, and some people have even misguidedly
recommended use of --playlist with untrusted sources. Do NOT
use --playlist with random internet sources or files you do
not trust!
Playlist can contain entries using other protocols, such as
local files, or (most severely), special protocols like avde‐
vice://, which are inherently unsafe.
...
Due to the changed syntax of the --playlist argument, coupled with the warning
in MPV's manual, I changed the above highlighted form to simply "--" in
`emms-player-mpv-start'. With my minimal testing it's working fine, though to
change the code in the package it probably needs more testing.
Let me know what I can do to help!
--
~ acdw
acdw.net | breadpunk.club/~breadw
- BUG: MPV playlist arguments are out-of-date,
acdw <=