国标级联-修复拉流代理播放
This commit is contained in:
@@ -151,7 +151,7 @@ public class ZLMHttpHookListener {
|
||||
logger.info("[ZLM HOOK] 播放鉴权 失败:{}->{}", param.getMediaServerId(), param);
|
||||
return new HookResult(401, "Unauthorized");
|
||||
}
|
||||
logger.info("[ZLM HOOK] 播放鉴权 失败:{}->{}", param.getMediaServerId(), param);
|
||||
logger.info("[ZLM HOOK] 播放鉴权成功:{}->{}", param.getMediaServerId(), param);
|
||||
return HookResult.SUCCESS();
|
||||
}
|
||||
|
||||
|
||||
@@ -257,14 +257,13 @@ public class ZLMMediaNodeServerService implements IMediaNodeServerService {
|
||||
public WVPResult<String> addStreamProxy(MediaServer mediaServer, String app, String stream, String url, boolean enableAudio, boolean enableMp4, String rtpType) {
|
||||
JSONObject jsonObject = zlmresTfulUtils.addStreamProxy(mediaServer, app, stream, url, enableAudio, enableMp4, rtpType);
|
||||
if (jsonObject.getInteger("code") != 0) {
|
||||
logger.warn("[addStreamProxy] 添加代理失败");
|
||||
return WVPResult.fail(ErrorCode.ERROR100.getCode(), "添加代理失败");
|
||||
}else {
|
||||
JSONObject data = jsonObject.getJSONObject("data");
|
||||
if (data == null) {
|
||||
return WVPResult.fail(ErrorCode.ERROR100.getCode(), "代理结果异常: " + jsonObject);
|
||||
}else {
|
||||
return WVPResult.success("");
|
||||
return WVPResult.success(data.getString("key"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user