Add &params= option to librespot to support other librespot parameters.

This commit is contained in:
Alexandre Macabies 2020-09-01 02:34:16 +02:00 committed by badaix
parent 469bfeb1f8
commit 57c0c5262a
2 changed files with 3 additions and 2 deletions

View file

@ -51,7 +51,7 @@ LibrespotStream::LibrespotStream(PcmListener* pcmListener, boost::asio::io_conte
if (username.empty() != password.empty())
throw SnapException("missing parameter \"username\" or \"password\" (must provide both, or neither)");
params_ = "--name \"" + devicename + "\"";
params_ += "--name \"" + devicename + "\"";
if (!username.empty() && !password.empty())
params_ += " --username \"" + username + "\" --password \"" + password + "\"";
params_ += " --bitrate " + bitrate + " --backend pipe";