Fix gvisor changes

Signed-off-by: Vasyl Gello <vasek.gello@gmail.com>
This commit is contained in:
Vasyl Gello 2024-07-24 18:23:43 +03:00
parent f0eecd21d4
commit 9da884697a
No known key found for this signature in database
GPG key ID: 8A52BC6C291FB280

View file

@ -97,12 +97,16 @@ func (e *YggdrasilNIC) IsAttached() bool { return e.dispatcher != nil }
func (e *YggdrasilNIC) MTU() uint32 { return uint32(e.ipv6rwc.MTU()) }
func (e *YggdrasilNIC) SetMTU(uint32) {}
func (*YggdrasilNIC) Capabilities() stack.LinkEndpointCapabilities { return stack.CapabilityNone }
func (*YggdrasilNIC) MaxHeaderLength() uint16 { return 40 }
func (*YggdrasilNIC) LinkAddress() tcpip.LinkAddress { return "" }
func (*YggdrasilNIC) SetLinkAddress(tcpip.LinkAddress) {}
func (*YggdrasilNIC) Wait() {}
func (e *YggdrasilNIC) writePacket(
@ -168,8 +172,9 @@ func (e *YggdrasilNIC) ParseHeader(*stack.PacketBuffer) bool {
return true
}
func (e *YggdrasilNIC) Close() error {
func (e *YggdrasilNIC) Close() {
e.stack.stack.RemoveNIC(1)
e.dispatcher = nil
return nil
}
func (e *YggdrasilNIC) SetOnCloseAction(func()) {}