shithub: riscv

Download patch

ref: acc45bda27cbeaa75f72d1d7ff2d460fe7d37d5e
parent: 05d0456a3037effc4894b56acf49b4a31e3bfe8f
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Fri Oct 6 15:44:18 EDT 2023

devpipe: remove bogus "wstat on closed pipe" note

This cannot happen ever. qsetlimit() will never
raise an error and it would only go into the waserror()
case when invalid argument checks fail.

--- a/sys/src/9/port/devpipe.c
+++ b/sys/src/9/port/devpipe.c
@@ -371,13 +371,6 @@
 	Dir d;
 	Pipe *p;
 
-	if(waserror()){
-		/* avoid notes when pipe is a mounted queue */
-		if((c->flag & CMSG) == 0)
-			postnote(up, 1, "sys: wstat on closed pipe", NUser);
-		nexterror();
-	}
-
 	n = convM2D(dp, n, &d, nil);
 	if(n == 0)
 		error(Eshortstat);
@@ -397,7 +390,6 @@
 		panic("pipewstat");
 	}
 
-	poperror();
 	return n;
 }