svn commit: r234536 - head/lib/libc/stdio

David Schultz das at FreeBSD.org
Sat Apr 21 07:31:28 UTC 2012


Author: das
Date: Sat Apr 21 07:31:27 2012
New Revision: 234536
URL: http://svn.freebsd.org/changeset/base/234536

Log:
  As noted by Peter Jeremy, r234528 only partially fixed the infinite
  loop bug introduced in r187302.  This completes the fix.
  
  PR:		167039
  MFC after:	3 days

Modified:
  head/lib/libc/stdio/fputws.c

Modified: head/lib/libc/stdio/fputws.c
==============================================================================
--- head/lib/libc/stdio/fputws.c	Sat Apr 21 07:00:39 2012	(r234535)
+++ head/lib/libc/stdio/fputws.c	Sat Apr 21 07:31:27 2012	(r234536)
@@ -61,8 +61,8 @@ fputws_l(const wchar_t * __restrict ws, 
 	uio.uio_iov = &iov;
 	uio.uio_iovcnt = 1;
 	iov.iov_base = buf;
+	wsp = ws;
 	do {
-		wsp = ws;
 		nbytes = l->__wcsnrtombs(buf, &wsp, SIZE_T_MAX, sizeof(buf),
 		    &fp->_mbstate);
 		if (nbytes == (size_t)-1)


More information about the svn-src-head mailing list