diff --git a/lib/libc/stdio/fputws.c b/lib/libc/stdio/fputws.c index a318e2d8acd..d9dc4dfbf21 100644 --- a/lib/libc/stdio/fputws.c +++ b/lib/libc/stdio/fputws.c @@ -70,7 +70,7 @@ fputws_l(const wchar_t * __restrict ws, FILE * __restrict fp, locale_t locale) iov.iov_len = uio.uio_resid = nbytes; if (__sfvwrite(fp, &uio) != 0) goto error; - } while (ws != NULL); + } while (wsp != NULL); FUNLOCKFILE(fp); return (0);