Browse Source

优化录像结束发送BYE判断

pull/473/head
648540858 3 years ago
parent
commit
95642d0bb8
  1. 7
      src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java

7
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java

@ -657,8 +657,11 @@ public class SIPCommander implements ISIPCommander {
// 添加流注销的订阅,注销了后向设备发送bye // 添加流注销的订阅,注销了后向设备发送bye
subscribe.addSubscribe(ZLMHttpHookSubscribe.HookType.on_stream_changed, subscribeKey, subscribe.addSubscribe(ZLMHttpHookSubscribe.HookType.on_stream_changed, subscribeKey,
(MediaServerItem mediaServerItemForEnd, JSONObject jsonForEnd)->{ (MediaServerItem mediaServerItemForEnd, JSONObject jsonForEnd)->{
logger.info("[录像]下载结束, 发送BYE"); ClientTransaction transaction = streamSession.getTransaction(device.getDeviceId(), channelId, ssrcInfo.getStream(), callIdHeader.getCallId());
streamByeCmd(device.getDeviceId(), channelId, ssrcInfo.getStream(), callIdHeader.getCallId()); if (transaction != null) {
logger.info("[录像]下载结束, 发送BYE");
streamByeCmd(device.getDeviceId(), channelId, ssrcInfo.getStream(), callIdHeader.getCallId());
}
}); });
}); });

Loading…
Cancel
Save