mirror of
https://github.com/badaix/snapcast.git
synced 2025-05-10 23:56:43 +02:00
added optional parameter "logStderr" to ProcessStream
This commit is contained in:
parent
ce8ed1e3f3
commit
7af0bdde65
3 changed files with 24 additions and 20 deletions
|
@ -39,8 +39,8 @@ SpotifyStream::SpotifyStream(PcmListener* pcmListener, const StreamUri& uri) : P
|
|||
if (password.empty())
|
||||
throw SnapException("missing parameter \"password\"");
|
||||
|
||||
params = "--name \"" + devicename + "\" --username \"" + username + "\" --password \"" + password + "\" --bitrate " + bitrate + " --backend stdout";
|
||||
logO << "params: " << params << "\n";
|
||||
params_ = "--name \"" + devicename + "\" --username \"" + username + "\" --password \"" + password + "\" --bitrate " + bitrate + " --backend stdout";
|
||||
// logO << "params: " << params << "\n";
|
||||
}
|
||||
|
||||
|
||||
|
@ -51,16 +51,16 @@ SpotifyStream::~SpotifyStream()
|
|||
|
||||
void SpotifyStream::initExeAndPath(const std::string& filename)
|
||||
{
|
||||
exe = findExe(filename);
|
||||
if (!fileExists(exe) || (exe == "/"))
|
||||
exe_ = findExe(filename);
|
||||
if (!fileExists(exe_) || (exe_ == "/"))
|
||||
{
|
||||
exe = findExe("librespot");
|
||||
if (!fileExists(exe))
|
||||
exe_ = findExe("librespot");
|
||||
if (!fileExists(exe_))
|
||||
throw SnapException("librespot not found");
|
||||
}
|
||||
|
||||
if (exe.find("/") != string::npos)
|
||||
path = exe.substr(0, exe.find_last_of("/"));
|
||||
if (exe_.find("/") != string::npos)
|
||||
path_ = exe_.substr(0, exe_.find_last_of("/"));
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue