Revert "mpd: workaround command termination bug in mpd server v0.18"
This reverts commit a6a73f47
, because the issue was solved in mpd
release 0.18.2. I imported the workaround for historical reasons and
in case someone gets stuck with version 0.18 on his preferred OS
distribution.
This commit is contained in:
parent
a6a73f47d6
commit
75cd1039cf
|
@ -37,11 +37,10 @@ local function worker(format, warg)
|
|||
|
||||
-- Construct MPD client options
|
||||
local mpdh = "telnet://"..host..":"..port
|
||||
local echo = '{ echo "password '..pass..'"; echo "status";' ..
|
||||
'echo "currentsong"; sleep .1; echo "close";}'
|
||||
local echo = "echo 'password "..pass.."\nstatus\ncurrentsong\nclose'"
|
||||
|
||||
-- Get data from MPD server
|
||||
local f = io.popen(echo.." | curl --connect-timeout 1 -fs "..mpdh)
|
||||
local f = io.popen(echo.." | curl --connect-timeout 1 -fsm 3 "..mpdh)
|
||||
|
||||
for line in f:lines() do
|
||||
for k, v in string.gmatch(line, "([%w]+):[%s](.*)$") do
|
||||
|
|
Loading…
Reference in New Issue