mirror of
https://gitee.com/pan648540858/wvp-GB28181-pro.git
synced 2026-05-18 19:37:50 +08:00
SIP只有一个监听时,直接返回
This commit is contained in:
parent
70e6d919e9
commit
07a8ef9e25
@ -142,6 +142,9 @@ public class SipLayer implements CommandLineRunner {
|
||||
if (ObjectUtils.isEmpty(ip)) {
|
||||
return null;
|
||||
}
|
||||
if (udpSipProviderMap.size() == 1) {
|
||||
return udpSipProviderMap.values().stream().findFirst().get();
|
||||
}
|
||||
return udpSipProviderMap.get(ip);
|
||||
}
|
||||
|
||||
@ -163,6 +166,9 @@ public class SipLayer implements CommandLineRunner {
|
||||
if (ObjectUtils.isEmpty(ip)) {
|
||||
return null;
|
||||
}
|
||||
if (tcpSipProviderMap.size() == 1) {
|
||||
return tcpSipProviderMap.values().stream().findFirst().get();
|
||||
}
|
||||
return tcpSipProviderMap.get(ip);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user