mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-02-03 22:18:39 +00:00
all: support h3:// protocol prefix
This commit is contained in:
committed by
Cuong Manh Le
parent
082d14a9ba
commit
08fe04f1ee
@@ -1473,7 +1473,11 @@ func processNoConfigFlags(noConfigStart bool) {
|
||||
|
||||
endpointAndTyp := func(endpoint string) (string, string) {
|
||||
typ := ctrld.ResolverTypeFromEndpoint(endpoint)
|
||||
return strings.TrimPrefix(endpoint, "quic://"), typ
|
||||
endpoint = strings.TrimPrefix(endpoint, "quic://")
|
||||
if after, found := strings.CutPrefix(endpoint, "h3://"); found {
|
||||
endpoint = "https://" + after
|
||||
}
|
||||
return endpoint, typ
|
||||
}
|
||||
pEndpoint, pType := endpointAndTyp(primaryUpstream)
|
||||
upstream := map[string]*ctrld.UpstreamConfig{
|
||||
|
||||
Reference in New Issue
Block a user