remove NodeARP in favor of arp.Handler; fix bug in IP stack node handling; use registerNode where applicable

This commit is contained in:
soypat
2025-07-14 19:48:29 -03:00
parent 1549e563e9
commit 61c66a2e58
9 changed files with 29 additions and 32 deletions
+2 -2
View File
@@ -29,7 +29,7 @@ func (sudp *StackUDPPort) LocalPort() uint16 { return sudp.h.port }
func (sudp *StackUDPPort) ConnectionID() *uint64 { return sudp.h.connID }
func (sudp *StackUDPPort) Demux(carrierData []byte, frameOffset int) error {
if checkNode(&sudp.h) {
if sudp.h.IsInvalid() {
sudp.h.destroy()
return net.ErrClosed
}
@@ -62,7 +62,7 @@ func (sudp *StackUDPPort) Demux(carrierData []byte, frameOffset int) error {
}
func (sudp *StackUDPPort) Encapsulate(carrierData []byte, frameOffset int) (int, error) {
if checkNode(&sudp.h) {
if sudp.h.IsInvalid() {
sudp.h.destroy()
return 0, net.ErrClosed
}