From 929273386f6e688c008b15fd24932df2ed7e7172 Mon Sep 17 00:00:00 2001 From: Jason Evans Date: Wed, 12 Jan 2000 09:23:48 +0000 Subject: Add three-tier symbol naming in support of POSIX thread cancellation points. For library functions, the pattern is __sleep() <-- _libc_sleep() <-- sleep(). The arrows represent weak aliases. For system calls, the pattern is _read() <-- _libc_read() <-- read(). --- lib/libc/stdio/stdio.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/libc/stdio/stdio.c') diff --git a/lib/libc/stdio/stdio.c b/lib/libc/stdio/stdio.c index e12dc28ab9dc..777f33677ec0 100644 --- a/lib/libc/stdio/stdio.c +++ b/lib/libc/stdio/stdio.c @@ -60,7 +60,7 @@ __sread(cookie, buf, n) register FILE *fp = cookie; register int ret; - ret = read(fp->_file, buf, (size_t)n); + ret = _libc_read(fp->_file, buf, (size_t)n); /* if the read succeeded, update the current offset */ if (ret >= 0) fp->_offset += ret; @@ -80,7 +80,7 @@ __swrite(cookie, buf, n) if (fp->_flags & __SAPP) (void) lseek(fp->_file, (off_t)0, SEEK_END); fp->_flags &= ~__SOFF; /* in case FAPPEND mode is set */ - return (write(fp->_file, buf, (size_t)n)); + return (_libc_write(fp->_file, buf, (size_t)n)); } fpos_t @@ -107,5 +107,5 @@ __sclose(cookie) void *cookie; { - return (close(((FILE *)cookie)->_file)); + return (_libc_close(((FILE *)cookie)->_file)); } -- cgit v1.2.3