Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix httpclient proxy with host and port #4124

Merged
merged 2 commits into from
Apr 6, 2021

Conversation

Yurunsoft
Copy link
Member

No description provided.

@twose
Copy link
Member

twose commented Apr 2, 2021

没看懂 host里不会有:
这个规则是不是应该根据下面的 if (!ssl ? port != 80 : port != 443) 的时候不加端口

@Yurunsoft
Copy link
Member Author

问题就出在手动设定请求头的Host,里面是host:port格式的话,设置代理后,会请求成host:port:port

@codecov
Copy link

codecov bot commented Apr 6, 2021

Codecov Report

Merging #4124 (79d13be) into master (ab994a0) will decrease coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #4124      +/-   ##
==========================================
- Coverage   48.81%   48.77%   -0.05%     
==========================================
  Files          71       71              
  Lines       14280    14280              
==========================================
- Hits         6971     6965       -6     
- Misses       7309     7315       +6     
Impacted Files Coverage Δ
src/protocol/base.cc 63.15% <0.00%> (-1.98%) ⬇️
src/os/async_thread.cc 68.42% <0.00%> (-1.32%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ab994a0...79d13be. Read the comment docs.

@matyhtf matyhtf merged commit efb83c8 into swoole:master Apr 6, 2021
Yurunsoft added a commit to Yurunsoft/swoole-src that referenced this pull request Apr 8, 2021
* Fix proxy with host and port

* Change strstr to memchr
# Conflicts:
#	swoole_http_client_coro.cc
matyhtf pushed a commit that referenced this pull request Apr 8, 2021
* Fix httpclient proxy with host and port (#4124)

* Fix proxy with host and port

* Change strstr to memchr
# Conflicts:
#	swoole_http_client_coro.cc

* Update version for Swoole 4.4.25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants