Do not only warn if the protocol is empty

This commit is contained in:
Frank Denis 2020-12-17 01:08:06 +01:00
parent 85e7dddc9b
commit 7d851366bb
1 changed files with 1 additions and 1 deletions

View File

@ -477,7 +477,7 @@ func fetchDoHServerInfo(proxy *Proxy, name string, stamp stamps.ServerStamp, isN
dlog.Criticalf("[%s] may be a lying resolver", name)
}
protocol := tls.NegotiatedProtocol
if len(protocol) == 0 {
if len(protocol) == 0 || strings.HasPrefix(protocol, "http/1.") {
protocol = "h1"
dlog.Warnf("[%s] does not support HTTP/2", name)
}