We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e0ea5d0 commit fa413fcCopy full SHA for fa413fc
tonic/src/transport/server/incoming.rs
@@ -70,6 +70,11 @@ impl TcpIncoming {
70
let keepalive = keepalive.map(|t| TcpKeepalive::new().with_time(t));
71
Self { keepalive, ..self }
72
}
73
+
74
+ /// Returns the local address that this tcp incoming is bound to.
75
+ pub fn local_addr(&self) -> std::io::Result<SocketAddr> {
76
+ self.inner.as_ref().local_addr()
77
+ }
78
79
80
impl From<TcpListener> for TcpIncoming {
0 commit comments