git: plan9front

Download patch

ref: c91d99c5de064d471350214810b84891ffc0f59f
parent: 439a525113acb211b3ebb7475a1e5368e458bec6
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sat Jul 27 18:03:48 EDT 2024

devip: dont shoot the messenger (dont unbind the interface when ipipu4/ipiput6 errors)

The medium should only self-unbind when we get a read error
from the device, not when ipiput4/8() throw an error,
which can happen for the nullmedium.

--- a/sys/src/9/ip/ethermedium.c
+++ b/sys/src/9/ip/ethermedium.c
@@ -338,7 +338,7 @@
 		rlock(ifc);
 		if(waserror()){
 			runlock(ifc);
-			nexterror();
+			continue;
 		}
 		ifc->in++;
 		if(ifc->lifc == nil || BLEN(bp) <= ETHERHDRSIZE)
@@ -379,7 +379,7 @@
 		rlock(ifc);
 		if(waserror()){
 			runlock(ifc);
-			nexterror();
+			continue;
 		}
 		ifc->in++;
 		if(ifc->lifc == nil || BLEN(bp) <= ETHERHDRSIZE)
--- a/sys/src/9/ip/netdevmedium.c
+++ b/sys/src/9/ip/netdevmedium.c
@@ -120,7 +120,7 @@
 		rlock(ifc);
 		if(waserror()){
 			runlock(ifc);
-			nexterror();
+			continue;
 		}
 		ifc->in++;
 		if(ifc->lifc == nil)
--