server: Make Request.RemoteAddr a net.Addr
A concrete type is better.
This commit is contained in:
parent
8938038797
commit
2308c6407f
@ -4,6 +4,7 @@ import (
|
|||||||
"bufio"
|
"bufio"
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"io"
|
"io"
|
||||||
|
"net"
|
||||||
"net/url"
|
"net/url"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -32,12 +33,9 @@ type Request struct {
|
|||||||
|
|
||||||
// RemoteAddr allows Gemini servers and other software to record
|
// RemoteAddr allows Gemini servers and other software to record
|
||||||
// the network address that sent the request, usually for
|
// the network address that sent the request, usually for
|
||||||
// logging. This field is not filled in by ReadRequest and
|
// logging. This field is not filled in by ReadRequest.
|
||||||
// has no defined format. The Gemini server in this package
|
|
||||||
// sets RemoteAddr to an "IP:port" address before invoking a
|
|
||||||
// handler.
|
|
||||||
// This field is ignored by the Gemini client.
|
// This field is ignored by the Gemini client.
|
||||||
RemoteAddr string
|
RemoteAddr net.Addr
|
||||||
|
|
||||||
// TLS allows Gemini servers and other software to record
|
// TLS allows Gemini servers and other software to record
|
||||||
// information about the TLS connection on which the request
|
// information about the TLS connection on which the request
|
||||||
|
Loading…
Reference in New Issue
Block a user