aboutsummaryrefslogtreecommitdiff
path: root/libio
diff options
context:
space:
mode:
Diffstat (limited to 'libio')
-rw-r--r--libio/filedoalloc.c6
-rw-r--r--libio/fileops.c16
2 files changed, 11 insertions, 11 deletions
diff --git a/libio/filedoalloc.c b/libio/filedoalloc.c
index f71656478c..045bff697d 100644
--- a/libio/filedoalloc.c
+++ b/libio/filedoalloc.c
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 1993 Free Software Foundation
This file is part of the GNU IO Library. This library is free
@@ -77,7 +77,7 @@ DEFUN(_IO_file_doallocate, (fp),
to get called by any program that does buffered I/O. */
if (_IO_cleanup_registration_needed)
(*_IO_cleanup_registration_needed)();
-
+
if (fp->_fileno < 0 || _IO_SYSSTAT (fp, &st) < 0)
{
couldbetty = 0;
@@ -100,7 +100,7 @@ DEFUN(_IO_file_doallocate, (fp),
if (p == NULL)
return EOF;
_IO_setb(fp, p, p+size, 1);
- if (couldbetty && isatty(fp->_fileno))
+ if (couldbetty && __isatty (fp->_fileno))
fp->_flags |= _IO_LINE_BUF;
return 1;
}
diff --git a/libio/fileops.c b/libio/fileops.c
index 828f99db96..a3138afd16 100644
--- a/libio/fileops.c
+++ b/libio/fileops.c
@@ -1,4 +1,4 @@
-/*
+/*
Copyright (C) 1993, 1995 Free Software Foundation
This file is part of the GNU IO Library. This library is free
@@ -70,14 +70,14 @@ extern int errno;
(The pointers save_gptr() and save_egptr() are the values
of gptr() and egptr() at the time putback mode was entered.)
The OS position corresponds to that of save_egptr().
-
+
LINE BUFFERED OUTPUT:
During line buffered output, pbase()==base() && epptr()==base().
However, ptr() may be anywhere between base() and ebuf().
This forces a call to filebuf::overflow(int C) on every put.
If there is more space in the buffer, and C is not a '\n',
then C is inserted, and pptr() incremented.
-
+
UNBUFFERED STREAMS:
If a filebuf is unbuffered(), the _shortbuf[1] is used as the buffer.
*/
@@ -172,7 +172,7 @@ DEFUN(_IO_file_fopen, (fp, filename, mode),
omode = O_RDWR;
read_write &= _IO_IS_APPENDING;
}
- fdesc = open(filename, omode|oflags, oprot);
+ fdesc = __open (filename, omode|oflags, oprot);
if (fdesc < 0)
return NULL;
fp->_fileno = fdesc;
@@ -230,7 +230,7 @@ DEFUN(_IO_do_write, (fp, data, to_do),
unpredictable. */
fp->_offset = _IO_pos_BAD;
else if (fp->_IO_read_end != fp->_IO_write_base)
- {
+ {
_IO_pos_t new_pos
= _IO_SYSSEEK(fp, fp->_IO_write_base - fp->_IO_read_end, 1);
if (new_pos == _IO_pos_BAD)
@@ -339,7 +339,7 @@ DEFUN(_IO_file_sync, (fp),
/* char* ptr = cur_ptr(); */
if (fp->_IO_write_ptr > fp->_IO_write_base)
if (_IO_do_flush(fp)) return EOF;
- delta = fp->_IO_read_ptr - fp->_IO_read_end;
+ delta = fp->_IO_read_ptr - fp->_IO_read_end;
if (delta != 0)
{
#ifdef TODO
@@ -641,7 +641,7 @@ DEFUN(_IO_file_xsputn, (f, data, n),
if (_IO_do_write(f, s, count) == EOF)
return n - to_do;
to_do = dont_write;
-
+
/* Now write out the remainder. Normally, this will fit in the
buffer, but it's somewhat messier for line-buffered files,
so we let _IO_default_xsputn handle the general case. */
@@ -706,7 +706,7 @@ DEFUN(_IO_file_xsgetn, (fp, data, n),
else
fp->_flags |= _IO_ERR_SEEN, count = 0;
}
-
+
s += count;
more -= count;
}