mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-06-14 20:15:58 +08:00
addStreamProxy支持透传参数并设置MediaPlayer (#3063)
通过addStreamProxy接口可以直接配置MediaPlayer相关设置参数,比如说http代理url等
This commit is contained in:
@@ -78,15 +78,16 @@ void HttpClient::sendRequest(const string &url) {
|
||||
printer.pop_back();
|
||||
_header.emplace("Cookie", printer);
|
||||
}
|
||||
if (isUsedProxy()) {
|
||||
startConnect(_proxy_host, _proxy_port, _wait_header_ms / 1000.0f);
|
||||
} else {
|
||||
if (!alive() || host_changed) {
|
||||
startConnect(host, port, _wait_header_ms / 1000.0f);
|
||||
if (!alive() || host_changed) {
|
||||
if (isUsedProxy()) {
|
||||
_proxy_connected = false;
|
||||
startConnect(_proxy_host, _proxy_port, _wait_header_ms / 1000.0f);
|
||||
} else {
|
||||
SockException ex;
|
||||
onConnect_l(ex);
|
||||
startConnect(host, port, _wait_header_ms / 1000.0f);
|
||||
}
|
||||
} else {
|
||||
SockException ex;
|
||||
onConnect_l(ex);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user