Displaying 3 results from an estimated 3 matches for "_io_fileno".
Did you mean:
_io_file
2020 Jul 25
0
[klibc:master] stdio: Define all the _unlocked functions and macros
..., s, n, f) fread((p), (s), (n), (f))
__extern_inline size_t
fwrite(const void *__p, size_t __s, size_t __n, FILE * __f)
{
return _fwrite(__p, __s * __n, __f) / __s;
}
+#define fwrite_unlocked(p, s, n, f) fwrite((p), (s), (n), (f))
__extern_inline int fileno(FILE *__f)
{
return __f->_IO_fileno;
}
+#define fileno_unlocked(f) fileno(f)
__extern_inline int ferror(FILE *__f)
{
return __f->_IO_error;
}
+#define ferror_unlocked(f) ferror(f)
__extern_inline int feof(FILE *__f)
{
return __f->_IO_eof;
}
+#define feof_unlocked(f) feof(f)
__extern_inline void clearerr(FILE *...
2016 Feb 01
0
[klibc:master] fwrite: flush before a large write to allow better bypass
...- if (f->obytes == 0 && count >= f->bufsiz) {
+ if (count >= f->bufsiz) {
/*
- * The buffer is empty and the write is large,
- * so bypass the buffering entirely.
+ * The the write is large, so bypass
+ * buffering entirely.
*/
rv = write(f->pub._IO_fileno, p, count);
if (rv == -1) {
2016 Feb 01
0
[klibc:master] fwrite: fix typo in comment
...fwrite.c
+++ b/usr/klibc/stdio/fwrite.c
@@ -21,7 +21,7 @@ static size_t fwrite_noflush(const void *buf, size_t count,
if (count >= f->bufsiz) {
/*
- * The the write is large, so bypass
+ * The write is large, so bypass
* buffering entirely.
*/
rv = write(f->pub._IO_fileno, p, count);