rewrite ControlBlock.Open to only open passive connections; now use Send for active connections

This commit is contained in:
soypat
2025-02-13 22:56:27 -03:00
parent 0cb43c47a4
commit bbd74d04d8
6 changed files with 88 additions and 29 deletions
+5 -1
View File
@@ -70,11 +70,15 @@ func main() {
if err != nil {
log.Fatal(err)
}
log.Println("success receiving packet")
n, err := lStack.HandleEth(buf)
if err != nil {
log.Fatal(n, err)
} else if n > 0 {
log.Println("success sending packet")
} else {
log.Println("no packet sent")
}
log.Println("success receiving packet")
}
type Handler interface {