From 898ffc9300e4de51d094e8d419ce9a60a8b7d830 Mon Sep 17 00:00:00 2001 From: ericb Date: Thu, 19 Jul 2007 03:42:21 +0000 Subject: [PATCH] Fix 'make info'. * libc/stdio/stdio.tex: Add missing include. * libc/stdio/vfprintf.c: Use expected node name. * libc/stdio/vfscanf.c: Likewise. * libc/stdio/sscanf.c: Likewise. * libc/stdio/sprintf.c: Likewise. * libc/stdio/siscanf.c: Likewise. * libc/stdio/siprintf.c: Likewise. * libc/stdio/fopencookie.c: Quote raw {}. Reported by DJ Delorie. --- newlib/ChangeLog | 13 +++++++++++++ newlib/libc/stdio/fopencookie.c | 23 +++++++++++++---------- newlib/libc/stdio/siprintf.c | 2 +- newlib/libc/stdio/siscanf.c | 2 +- newlib/libc/stdio/sprintf.c | 2 +- newlib/libc/stdio/sscanf.c | 2 +- newlib/libc/stdio/stdio.tex | 3 +++ newlib/libc/stdio/vfprintf.c | 6 +++--- newlib/libc/stdio/vfscanf.c | 6 +++--- 9 files changed, 39 insertions(+), 20 deletions(-) diff --git a/newlib/ChangeLog b/newlib/ChangeLog index 94f1438f1f..042c17d648 100644 --- a/newlib/ChangeLog +++ b/newlib/ChangeLog @@ -1,3 +1,16 @@ +2007-07-18 Eric Blake + + Fix 'make info'. + * libc/stdio/stdio.tex: Add missing include. + * libc/stdio/vfprintf.c: Use expected node name. + * libc/stdio/vfscanf.c: Likewise. + * libc/stdio/sscanf.c: Likewise. + * libc/stdio/sprintf.c: Likewise. + * libc/stdio/siscanf.c: Likewise. + * libc/stdio/siprintf.c: Likewise. + * libc/stdio/fopencookie.c: Quote raw {}. + Reported by DJ Delorie. + 2007-07-13 Eric Blake Fix fflush issues. diff --git a/newlib/libc/stdio/fopencookie.c b/newlib/libc/stdio/fopencookie.c index 581441be0c..35afa3257e 100644 --- a/newlib/libc/stdio/fopencookie.c +++ b/newlib/libc/stdio/fopencookie.c @@ -19,21 +19,24 @@ ANSI_SYNOPSIS typedef int (*cookie_seek_function_t)(void *_cookie, off_t *_off, int _whence); typedef int (*cookie_close_function_t)(void *_cookie); - typedef struct - { - cookie_read_function_t *read; - cookie_write_function_t *write; - cookie_seek_function_t *seek; - cookie_close_function_t *close; - } cookie_io_functions_t; FILE *fopencookie(const void *<[cookie]>, const char *<[mode]>, cookie_io_functions_t <[functions]>); DESCRIPTION <> creates a <> stream where I/O is performed using -custom callbacks. The stream is opened with <[mode]> treated as in -<>. The callbacks <[functions.read]> and <[functions.write]> -may only be NULL when <[mode]> does not require them. +custom callbacks. The callbacks are registered via the structure: + +. typedef struct +. { +. cookie_read_function_t *read; +. cookie_write_function_t *write; +. cookie_seek_function_t *seek; +. cookie_close_function_t *close; +. } cookie_io_functions_t; + +The stream is opened with <[mode]> treated as in <>. The +callbacks <[functions.read]> and <[functions.write]> may only be NULL +when <[mode]> does not require them. <[functions.read]> should return -1 on failure, or else the number of bytes read (0 on EOF). It is similar to <>, except that diff --git a/newlib/libc/stdio/siprintf.c b/newlib/libc/stdio/siprintf.c index d2b4e76c97..296a16ee0d 100644 --- a/newlib/libc/stdio/siprintf.c +++ b/newlib/libc/stdio/siprintf.c @@ -17,7 +17,7 @@ /* FUNCTION -<>, <>, <>, <>, <>, <>---format output (integer only) +<>, <>, <>, <>, <>, <>---format output (integer only) INDEX fiprintf diff --git a/newlib/libc/stdio/siscanf.c b/newlib/libc/stdio/siscanf.c index 2c69921ffa..15b25c1965 100644 --- a/newlib/libc/stdio/siscanf.c +++ b/newlib/libc/stdio/siscanf.c @@ -17,7 +17,7 @@ /* FUNCTION -<>, <>, <>---scan and format non-floating input +<>, <>, <>---scan and format non-floating input INDEX iscanf diff --git a/newlib/libc/stdio/sprintf.c b/newlib/libc/stdio/sprintf.c index d2203fb3cf..bdff0797dc 100644 --- a/newlib/libc/stdio/sprintf.c +++ b/newlib/libc/stdio/sprintf.c @@ -17,7 +17,7 @@ /* FUNCTION -<>, <>, <>, <>, <>, <>---format output +<>, <>, <>, <>, <>, <>---format output INDEX fprintf diff --git a/newlib/libc/stdio/sscanf.c b/newlib/libc/stdio/sscanf.c index a1987c58da..c0921e1e16 100644 --- a/newlib/libc/stdio/sscanf.c +++ b/newlib/libc/stdio/sscanf.c @@ -17,7 +17,7 @@ /* FUNCTION -<>, <>, <>---scan and format input +<>, <>, <>---scan and format input INDEX scanf diff --git a/newlib/libc/stdio/stdio.tex b/newlib/libc/stdio/stdio.tex index a3846eaed3..f312715236 100644 --- a/newlib/libc/stdio/stdio.tex +++ b/newlib/libc/stdio/stdio.tex @@ -151,6 +151,9 @@ structure. @include stdio/ftell.def @page +@include stdio/funopen.def + +@page @include stdio/fwrite.def @page diff --git a/newlib/libc/stdio/vfprintf.c b/newlib/libc/stdio/vfprintf.c index 5bbd7594f7..491369012b 100644 --- a/newlib/libc/stdio/vfprintf.c +++ b/newlib/libc/stdio/vfprintf.c @@ -36,13 +36,13 @@ /* FUNCTION -<>, <>, <>, <>, <>, <>---format argument list +<>, <>, <>, <>, <>, <>---format argument list INDEX - vprintf -INDEX vfprintf INDEX + vprintf +INDEX vsprintf INDEX vsnprintf diff --git a/newlib/libc/stdio/vfscanf.c b/newlib/libc/stdio/vfscanf.c index 79a1243309..68b55f4268 100644 --- a/newlib/libc/stdio/vfscanf.c +++ b/newlib/libc/stdio/vfscanf.c @@ -17,13 +17,13 @@ /* FUNCTION -<>, <>, <>---format argument list +<>, <>, <>---format argument list INDEX - vscanf -INDEX vfscanf INDEX + vscanf +INDEX vsscanf ANSI_SYNOPSIS -- 2.11.0