Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Dec 2003 11:36:38 -0800 (PST)
From:      Nate Lawson <nate@root.org>
To:        Daniel Eischen <eischen@vigrid.com>
Cc:        cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/lib/libc_r/uthread uthread_write.c
Message-ID:  <20031217113610.N70711@root.org>
In-Reply-To: <Pine.GSO.4.10.10312171413360.15504-100000@pcnet5.pcnet.com>
References:  <Pine.GSO.4.10.10312171413360.15504-100000@pcnet5.pcnet.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 17 Dec 2003, Daniel Eischen wrote:
> On Wed, 17 Dec 2003, Nate Lawson wrote:
>
> > On Wed, 17 Dec 2003, Daniel Eischen wrote:
> > >   Modified files:
> > >     lib/libc_r/uthread   uthread_write.c
> > >   Log:
> > >   Return to the caller if write() returns 0.
> > >
> > >   PR:     59291
> > >
> > >   Revision  Changes    Path
> > >   1.23      +2 -0      src/lib/libc_r/uthread/uthread_write.c
> > >
> > > --- src/lib/libc_r/uthread/uthread_write.c:1.22	Mon Sep 29 06:41:26 2003
> > > +++ src/lib/libc_r/uthread/uthread_write.c	Wed Dec 17 08:44:03 2003
> > >  #include <sys/types.h>
> > > @@ -138,6 +138,8 @@
> > >  					ret = num;
> > >  				else
> > >  					ret = n;
> > > +				if (n == 0)
> > > +					break;
> > >
> > >  			/* Check if the write has completed: */
> > >  			} else if (num >= nbytes)
> >
> > Thanks!  Oh what a difference one retval makes.
>
> Does this fix something other than bacula?

Anyone else who expected this semantics.  I have no specific examples.

-Nate



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031217113610.N70711>