svn commit: r255856 - stable/9/sys/kern
Jaakko Heinonen
jh at FreeBSD.org
Tue Sep 24 17:09:29 UTC 2013
Author: jh
Date: Tue Sep 24 17:09:28 2013
New Revision: 255856
URL: http://svnweb.freebsd.org/changeset/base/255856
Log:
MFC r250706: A library function shall not set errno to 0.
Modified:
stable/9/sys/kern/subr_sbuf.c
Directory Properties:
stable/9/sys/ (props changed)
Modified: stable/9/sys/kern/subr_sbuf.c
==============================================================================
--- stable/9/sys/kern/subr_sbuf.c Tue Sep 24 17:01:29 2013 (r255855)
+++ stable/9/sys/kern/subr_sbuf.c Tue Sep 24 17:09:28 2013 (r255856)
@@ -706,9 +706,10 @@ sbuf_finish(struct sbuf *s)
#ifdef _KERNEL
return (s->s_error);
#else
- errno = s->s_error;
- if (s->s_error)
+ if (s->s_error != 0) {
+ errno = s->s_error;
return (-1);
+ }
return (0);
#endif
}
More information about the svn-src-stable-9
mailing list