summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/link/fdbased/endpoint.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/tcpip/link/fdbased/endpoint.go')
-rw-r--r--pkg/tcpip/link/fdbased/endpoint.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/pkg/tcpip/link/fdbased/endpoint.go b/pkg/tcpip/link/fdbased/endpoint.go
index 24af428dd..3a79d13d4 100644
--- a/pkg/tcpip/link/fdbased/endpoint.go
+++ b/pkg/tcpip/link/fdbased/endpoint.go
@@ -231,14 +231,14 @@ func (e *endpoint) dispatch(largeV buffer.View) (bool, *tcpip.Error) {
}
var (
- p tcpip.NetworkProtocolNumber
- remoteLinkAddr, localLinkAddr tcpip.LinkAddress
+ p tcpip.NetworkProtocolNumber
+ remote, local tcpip.LinkAddress
)
if e.hdrSize > 0 {
eth := header.Ethernet(e.views[0])
p = eth.Type()
- remoteLinkAddr = eth.SourceAddress()
- localLinkAddr = eth.DestinationAddress()
+ remote = eth.SourceAddress()
+ local = eth.DestinationAddress()
} else {
// We don't get any indication of what the packet is, so try to guess
// if it's an IPv4 or IPv6 packet.
@@ -256,7 +256,7 @@ func (e *endpoint) dispatch(largeV buffer.View) (bool, *tcpip.Error) {
vv := buffer.NewVectorisedView(n, e.views[:used])
vv.TrimFront(e.hdrSize)
- e.dispatcher.DeliverNetworkPacket(e, remoteLinkAddr, localLinkAddr, p, vv)
+ e.dispatcher.DeliverNetworkPacket(e, remote, local, p, vv)
// Prepare e.views for another packet: release used views.
for i := 0; i < used; i++ {
@@ -297,7 +297,7 @@ func (e *InjectableEndpoint) Attach(dispatcher stack.NetworkDispatcher) {
// Inject injects an inbound packet.
func (e *InjectableEndpoint) Inject(protocol tcpip.NetworkProtocolNumber, vv buffer.VectorisedView) {
- e.dispatcher.DeliverNetworkPacket(e, "" /* remoteLinkAddr */, "" /* localLinkAddr */, protocol, vv)
+ e.dispatcher.DeliverNetworkPacket(e, "" /* remote */, "" /* local */, protocol, vv)
}
// NewInjectable creates a new fd-based InjectableEndpoint.