projects
/
gnulib.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fsusage: Restore previous behaviour on AIX, Cygwin, Interix.
[gnulib.git]
/
lib
/
fseeko.c
diff --git
a/lib/fseeko.c
b/lib/fseeko.c
index
7c0fd0e
..
abab5e9
100644
(file)
--- a/
lib/fseeko.c
+++ b/
lib/fseeko.c
@@
-1,5
+1,5
@@
/* An fseeko() function that, together with fflush(), is POSIX compliant.
/* An fseeko() function that, together with fflush(), is POSIX compliant.
- Copyright (C) 2007-201
0
Free Software Foundation, Inc.
+ Copyright (C) 2007-201
1
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@
-25,14
+25,13
@@
#include "stdio-impl.h"
#include "stdio-impl.h"
+int
+fseeko (FILE *fp, off_t offset, int whence)
#undef fseeko
#if !HAVE_FSEEKO
# undef fseek
# define fseeko fseek
#endif
#undef fseeko
#if !HAVE_FSEEKO
# undef fseek
# define fseeko fseek
#endif
-
-int
-rpl_fseeko (FILE *fp, off_t offset, int whence)
{
#if LSEEK_PIPE_BROKEN
/* mingw gives bogus answers rather than failure on non-seekable files. */
{
#if LSEEK_PIPE_BROKEN
/* mingw gives bogus answers rather than failure on non-seekable files. */
@@
-70,7
+69,7
@@
rpl_fseeko (FILE *fp, off_t offset, int whence)
&& fp->_rcount == 0
&& fp->_wcount == 0
&& fp->_ungetc_count == 0)
&& fp->_rcount == 0
&& fp->_wcount == 0
&& fp->_ungetc_count == 0)
-#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw */
+#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw
, NonStop Kernel
*/
if (fp_->_ptr == fp_->_base
&& (fp_->_ptr == NULL || fp_->_cnt == 0))
#elif defined __UCLIBC__ /* uClibc */
if (fp_->_ptr == fp_->_base
&& (fp_->_ptr == NULL || fp_->_cnt == 0))
#elif defined __UCLIBC__ /* uClibc */
@@
-132,7
+131,7
@@
rpl_fseeko (FILE *fp, off_t offset, int whence)
fp_->_flags &= ~__SEOF;
#elif defined __EMX__ /* emx+gcc */
fp->_flags &= ~_IOEOF;
fp_->_flags &= ~__SEOF;
#elif defined __EMX__ /* emx+gcc */
fp->_flags &= ~_IOEOF;
-#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw */
+#elif defined _IOERR /* AIX, HP-UX, IRIX, OSF/1, Solaris, OpenServer, mingw
, NonStop Kernel
*/
fp->_flag &= ~_IOEOF;
#elif defined __MINT__ /* Atari FreeMiNT */
fp->__offset = pos;
fp->_flag &= ~_IOEOF;
#elif defined __MINT__ /* Atari FreeMiNT */
fp->__offset = pos;