优化stopSendRtp接口返回值

This commit is contained in:
xiongziliang 2020-09-06 18:24:48 +08:00
parent 0878f776b3
commit 040c132fb6

View File

@ -837,7 +837,9 @@ void installWebApi() {
throw ApiRetException("该媒体流不存在", API::OtherFailed); throw ApiRetException("该媒体流不存在", API::OtherFailed);
} }
val["result"] = src->stopSendRtp(); if (!src->stopSendRtp()) {
throw ApiRetException("尚未开始推流,停止失败", API::OtherFailed);
}
}); });