diff options
author | Max Kellermann <max@musicpd.org> | 2019-01-21 14:36:43 +0100 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2019-01-21 14:36:43 +0100 |
commit | 754f4048a8ab2e4c698ef74c042dd839f369a47b (patch) | |
tree | 7a078d3140bef7833cee9499b78f88e35a312bc3 /src/output | |
parent | 037bb07d0884a51f953126d2fbc76094243d5249 (diff) |
output/shout: evaluate `tls` option only if TLS is enabled in libshout
Fixes build failure after commit
0cea67ee706d73acbd07a48e5d3b758ba016c1a8
Diffstat (limited to 'src/output')
-rw-r--r-- | src/output/plugins/ShoutOutputPlugin.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/output/plugins/ShoutOutputPlugin.cxx b/src/output/plugins/ShoutOutputPlugin.cxx index 81ba5fe42..eec956d2a 100644 --- a/src/output/plugins/ShoutOutputPlugin.cxx +++ b/src/output/plugins/ShoutOutputPlugin.cxx @@ -141,6 +141,7 @@ ShoutOutput::ShoutOutput(const ConfigBlock &block) protocol = SHOUT_PROTOCOL_HTTP; } +#ifdef SHOUT_TLS unsigned tls; value = block.GetBlockValue("tls"); if (value != nullptr) { @@ -159,6 +160,7 @@ ShoutOutput::ShoutOutput(const ConfigBlock &block) } else { tls = SHOUT_TLS_DISABLED; } +#endif if (shout_set_host(shout_conn, host) != SHOUTERR_SUCCESS || shout_set_port(shout_conn, port) != SHOUTERR_SUCCESS || @@ -170,7 +172,9 @@ ShoutOutput::ShoutOutput(const ConfigBlock &block) shout_set_format(shout_conn, shout_format) != SHOUTERR_SUCCESS || shout_set_protocol(shout_conn, protocol) != SHOUTERR_SUCCESS || +#ifdef SHOUT_TLS shout_set_tls(shout_conn, tls) != SHOUTERR_SUCCESS || +#endif shout_set_agent(shout_conn, "MPD") != SHOUTERR_SUCCESS) throw std::runtime_error(shout_get_error(shout_conn)); |