diff options
author | Ulrich Drepper <drepper@redhat.com> | 2000-08-13 18:18:28 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2000-08-13 18:18:28 +0000 |
commit | 319d719d86e2278ecca219c099c5d6d343a576a1 (patch) | |
tree | 5359adefb397437feb7cf3e0c27cab895bc86cc7 /libio/libioP.h | |
parent | 8a82cc302401f7beea53f0395bbba2030ffe587a (diff) | |
download | glibc-319d719d86e2278ecca219c099c5d6d343a576a1.tar.gz glibc-319d719d86e2278ecca219c099c5d6d343a576a1.tar.xz glibc-319d719d86e2278ecca219c099c5d6d343a576a1.zip |
Update.
2000-08-13 Ulrich Drepper <drepper@redhat.com> Benjamin Koznik <bkoz@redhat.com> * libio/fileops.c: Merge with libstdc++-v3. * libio/genops.c: Likewise. * libio/iofclose.c: Likewise. * libio/iofopen.c: Likewise. * libio/iofwide.c: Likewise. * libio/libio.h: Likewise. * libio/libioP.h: Likewise. * libio/stdfiles.c: Likewise. * libio/stdio.c: Likewise. * libio/wfileops.c: Likewise. * libio/wgenops.c: Likewise. * libio/Versions: Export functions needed by libstdc++-v3 in GLIBC_2.2.
Diffstat (limited to 'libio/libioP.h')
-rw-r--r-- | libio/libioP.h | 38 |
1 files changed, 30 insertions, 8 deletions
diff --git a/libio/libioP.h b/libio/libioP.h index 6d3b775704..4bbee9cba0 100644 --- a/libio/libioP.h +++ b/libio/libioP.h @@ -256,7 +256,7 @@ typedef int (*_IO_stat_t) __PMT ((_IO_FILE *, void *)); /* The 'showmany' hook can be used to get an image how much input is available. In many cases the answer will be 0 which means unknown but some cases one can provide real information. */ -typedef size_t (*_IO_showmanyc_t) __PMT ((_IO_FILE *)); +typedef int (*_IO_showmanyc_t) __PMT ((_IO_FILE *)); #define _IO_SHOWMANYC(FP) JUMP0 (__showmanyc, FP) #define _IO_WSHOWMANYC(FP) WJUMP0 (__showmanyc, FP) @@ -404,7 +404,7 @@ extern int _IO_default_stat __P ((_IO_FILE *, void *)); extern _IO_off64_t _IO_default_seek __P ((_IO_FILE *, _IO_off64_t, int)); extern int _IO_default_sync __P ((_IO_FILE *)); #define _IO_default_close ((_IO_close_t) _IO_default_sync) -extern size_t _IO_default_showmanyc __P ((_IO_FILE *)); +extern int _IO_default_showmanyc __P ((_IO_FILE *)); extern void _IO_default_imbue __P ((_IO_FILE *, void *)); extern struct _IO_jump_t _IO_file_jumps; @@ -433,13 +433,19 @@ extern int _IO_new_fsetpos64 __P ((_IO_FILE *, const _IO_fpos64_t *)); extern int _IO_old_fsetpos64 __P ((_IO_FILE *, const _IO_fpos64_t *)); -#define _IO_do_flush(_f) \ +#if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T +# define _IO_do_flush(_f) \ ((_f)->_mode <= 0 \ ? _IO_do_write(_f, (_f)->_IO_write_base, \ (_f)->_IO_write_ptr-(_f)->_IO_write_base) \ : _IO_wdo_write(_f, (_f)->_wide_data->_IO_write_base, \ ((_f)->_wide_data->_IO_write_ptr \ - (_f)->_wide_data->_IO_write_base))) +#else +# define _IO_do_flush(_f) \ + _IO_do_write(_f, (_f)->_IO_write_base, \ + (_f)->_IO_write_ptr-(_f)->_IO_write_base) +#endif #define _IO_old_do_flush(_f) \ _IO_old_do_write(_f, (_f)->_IO_write_base, \ (_f)->_IO_write_ptr-(_f)->_IO_write_base) @@ -708,14 +714,22 @@ extern int _IO_vscanf __P ((const char *, _IO_va_list)); # ifdef _IO_USE_OLD_IO_FILE # define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ { _IO_MAGIC+_IO_LINKED+_IO_IS_FILEBUF+FLAGS, \ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ 0, _IO_pos_BAD, 0, 0, { 0 }, &_IO_stdfile_##FD##_lock } # else -# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ +# if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T +# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ { _IO_MAGIC+_IO_LINKED+_IO_IS_FILEBUF+FLAGS, \ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ 0, _IO_pos_BAD, 0, 0, { 0 }, &_IO_stdfile_##FD##_lock, _IO_pos_BAD,\ NULL, WDP, 0 } +# else +# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ + { _IO_MAGIC+_IO_LINKED+_IO_IS_FILEBUF+FLAGS, \ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ + 0, _IO_pos_BAD, 0, 0, { 0 }, &_IO_stdfile_##FD##_lock, _IO_pos_BAD,\ + 0 } +# endif # endif #else # ifdef _IO_USE_OLD_IO_FILE @@ -724,11 +738,19 @@ extern int _IO_vscanf __P ((const char *, _IO_va_list)); 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ 0, _IO_pos_BAD } # else -# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ +# if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T +# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ { _IO_MAGIC+_IO_LINKED+_IO_IS_FILEBUF+FLAGS, \ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ 0, _IO_pos_BAD, 0, 0, { 0 }, 0, _IO_pos_BAD, \ NULL, WDP, 0 } +# else +# define FILEBUF_LITERAL(CHAIN, FLAGS, FD, WDP) \ + { _IO_MAGIC+_IO_LINKED+_IO_IS_FILEBUF+FLAGS, \ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, (_IO_FILE *) CHAIN, FD, \ + 0, _IO_pos_BAD, 0, 0, { 0 }, 0, _IO_pos_BAD, \ + 0 } +# endif # endif #endif |