Lines Matching refs:fp
49 __smakebuf(FILE *fp) in __smakebuf() argument
56 if (fp->_flags & __SNBF) { in __smakebuf()
57 fp->_bf._base = fp->_p = fp->_nbuf; in __smakebuf()
58 fp->_bf._size = 1; in __smakebuf()
61 flags = __swhatbuf(fp, &size, &couldbetty); in __smakebuf()
63 fp->_flags |= __SNBF; in __smakebuf()
64 fp->_bf._base = fp->_p = fp->_nbuf; in __smakebuf()
65 fp->_bf._size = 1; in __smakebuf()
69 fp->_bf._base = fp->_p = p; in __smakebuf()
70 fp->_bf._size = size; in __smakebuf()
71 if (couldbetty && isatty(fp->_file)) in __smakebuf()
73 fp->_flags |= flags; in __smakebuf()
80 __swhatbuf(FILE *fp, size_t *bufsize, int *couldbetty) in __swhatbuf() argument
84 if (fp->_file < 0 || fstat(fp->_file, &st) == -1) { in __swhatbuf()
103 fp->_blksize = st.st_blksize; in __swhatbuf()
104 return ((st.st_mode & S_IFMT) == S_IFREG && fp->_seek == __sseek ? in __swhatbuf()