解决录像回放未判断是否等待编码导致的回放失败

pull/110/head
panlinlin 2021-05-27 09:18:47 +08:00
parent e48fa711a3
commit d881cd7eb3
1 changed files with 2 additions and 2 deletions

View File

@ -476,9 +476,9 @@ public class SIPCommander implements ISIPCommander {
subscribeKey.put("app", "rtp");
subscribeKey.put("stream", streamId);
subscribeKey.put("regist", true);
logger.debug("录像回放添加订阅,订阅内容:" + subscribeKey.toString());
subscribe.addSubscribe(ZLMHttpHookSubscribe.HookType.on_stream_changed, subscribeKey, json->{
if (json.getJSONArray("tracks") == null) return;
if (waitTrack && json.getJSONArray("tracks") == null) return;
event.response(json);
subscribe.removeSubscribe(ZLMHttpHookSubscribe.HookType.on_stream_changed, subscribeKey);
});