]> Cypherpunks repositories - gostls13.git/commit
net/http: declare publicErr as a constant
authorJes Cok <xigua67damn@gmail.com>
Tue, 20 Jun 2023 11:35:10 +0000 (11:35 +0000)
committerDamien Neil <dneil@google.com>
Thu, 20 Jul 2023 16:57:26 +0000 (16:57 +0000)
commit2b82d70f856b91bf278a28fd697b69811e1335eb
tree6864c1b39c79ffc7604af65a213ea189759b9040
parentf51c55bfc382443b61ca3257c1ffea59eee2559f
net/http: declare publicErr as a constant

Do the same as the code above: "case err == errTooLarge", declare
publicErr as a constant to avoid runtime calls.

Change-Id: I50a9951232c70eff027b0da86c0bbb8bea51acbe
GitHub-Last-Rev: 71d4458ded3a1e99a0d027ccca6c9d6269a1ab06
GitHub-Pull-Request: golang/go#60884
Reviewed-on: https://go-review.googlesource.com/c/go/+/504456
Reviewed-by: Damien Neil <dneil@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Damien Neil <dneil@google.com>
Reviewed-by: Olif Oftimis <oftimisolif@gmail.com>
src/net/http/server.go