comments on proposed uthread_write.c changes

Dan Langille dan at langille.org
Sun Sep 7 08:14:31 PDT 2003


A problem with pthreads and EOT has been identified.  See PR 56274.  It
was suggested the solution was probably just a matter of changing one of
the >0 tests to >=0 in uthread_write.c

Any comments on that?

Here's a diff I came up with after looking at
src/lib/libc_r/uthreaduthread_write.c.  Any suggestions/comments?

I plan to apply and test this later in the week.

--- uthread_write.c	Sun Sep  7 11:01:13 2003
+++ uthread_write.c.org	Sun Sep  7 10:58:31 2003
@@ -131,7 +131,7 @@
 			 * If there was an error, return partial success
 			 * (if any bytes were written) or else the error:
 			 */
-			} else if (n <= 0) {
+			} else if (n < 0) {
 				if (num > 0)
 					ret = num;
 				else


More information about the freebsd-hackers mailing list