struct not_implemented : virtual caspar_exception {};
struct user_error : virtual caspar_exception {};
+struct expected_user_error : virtual user_error {};
struct not_supported : virtual user_error {};
std::string get_context();
CASPAR_LOG(error) << get_message_and_context(e) << " Turn on log level debug for stacktrace.";
pCurrentCommand->SetReplyString(L"404 " + pCurrentCommand->print() + L" FAILED\r\n");
}
+ catch (const expected_user_error& e)
+ {
+ CASPAR_LOG_CURRENT_EXCEPTION_AT_LEVEL(debug);
+ CASPAR_LOG(info) << get_message_and_context(e) << " Check syntax. Turn on log level debug for stacktrace.";
+ pCurrentCommand->SetReplyString(L"403 " + pCurrentCommand->print() + L" FAILED\r\n");
+ }
catch (const user_error& e)
{
CASPAR_LOG_CURRENT_EXCEPTION_AT_LEVEL(debug);
auto proxy = ctx.cg_registry->get_proxy(spl::make_shared_ptr(ctx.channel.channel), ctx.layer_index(core::cg_proxy::DEFAULT_LAYER));
if (proxy == cg_proxy::empty())
- CASPAR_THROW_EXCEPTION(user_error() << msg_info(L"No CG proxy running on layer"));
+ CASPAR_THROW_EXCEPTION(expected_user_error() << msg_info(L"No CG proxy running on layer"));
return proxy;
}