mirror of
https://github.com/badaix/snapcast.git
synced 2025-07-05 02:37:38 +02:00
Fix warnings on Windows
This commit is contained in:
parent
30753f9f61
commit
ade0ee7be3
13 changed files with 67 additions and 63 deletions
|
@ -62,7 +62,8 @@ void SampleFormat::setFormat(const std::string& format)
|
|||
std::vector<std::string> strs;
|
||||
strs = utils::string::split(format, ':');
|
||||
if (strs.size() == 3)
|
||||
setFormat(strs[0] == "*" ? 0 : cpt::stoul(strs[0]), strs[1] == "*" ? 0 : cpt::stoul(strs[1]), strs[2] == "*" ? 0 : cpt::stoul(strs[2]));
|
||||
setFormat(strs[0] == "*" ? 0 : cpt::stoul(strs[0]), strs[1] == "*" ? 0 : static_cast<uint16_t>(cpt::stoul(strs[1])),
|
||||
strs[2] == "*" ? 0 : static_cast<uint16_t>(cpt::stoul(strs[2])));
|
||||
else
|
||||
throw SnapException("sampleformat must be <rate>:<bits>:<channels>");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue