diff options
Diffstat (limited to 'newlib/libc/stdio64')
-rw-r--r-- | newlib/libc/stdio64/fseeko64.c | 5 | ||||
-rw-r--r-- | newlib/libc/stdio64/tmpfile64.c | 4 |
2 files changed, 4 insertions, 5 deletions
diff --git a/newlib/libc/stdio64/fseeko64.c b/newlib/libc/stdio64/fseeko64.c index 524aac32e..312883072 100644 --- a/newlib/libc/stdio64/fseeko64.c +++ b/newlib/libc/stdio64/fseeko64.c @@ -108,8 +108,7 @@ _DEFUN (_fseeko64_r, (ptr, fp, offset, whence), _fpos64_t target, curoff; size_t n; - /* FIXME: this should be stat64. */ - struct stat st; + struct stat64 st; int havepos; _flockfile(fp); @@ -205,7 +204,7 @@ _DEFUN (_fseeko64_r, (ptr, fp, offset, whence), { if (seekfn != __sseek64 || fp->_file < 0 - || _fstat_r (ptr, fp->_file, &st) + || _fstat64_r (ptr, fp->_file, &st) || (st.st_mode & S_IFMT) != S_IFREG) { fp->_flags |= __SNPT; diff --git a/newlib/libc/stdio64/tmpfile64.c b/newlib/libc/stdio64/tmpfile64.c index 1f97c071c..98689631f 100644 --- a/newlib/libc/stdio64/tmpfile64.c +++ b/newlib/libc/stdio64/tmpfile64.c @@ -63,9 +63,9 @@ _DEFUN (_tmpfile64_r, (ptr), if ((f = _tmpnam_r (ptr, buf)) == NULL) return NULL; - fp = fopen64 (f, "wb+"); + fp = _fopen64_r (ptr, (const char *)f, "wb+"); e = ptr->_errno; - _CAST_VOID remove (f); + _CAST_VOID _remove_r (ptr, f); ptr->_errno = e; return fp; } |