Loading...
stdio/FreeBSD/funopen.c Libc-763.13 Libc-825.25
--- Libc/Libc-763.13/stdio/FreeBSD/funopen.c
+++ Libc/Libc-825.25/stdio/FreeBSD/funopen.c
@@ -63,7 +63,8 @@
 		else
 			flags = __SRW;		/* read-write */
 	}
-	if ((fp = __sfp()) == NULL)
+	/* funopen in not covered in SUSv3, so never count the streams */
+	if ((fp = __sfp(0)) == NULL)
 		return (NULL);
 	fp->_flags = flags;
 	fp->_file = -1;