mescc: Mes C Library: Support gcc-4.6.4: Implement rewind.
* lib/stdio/rewind.c: Move from ../stub. Implement. * include/stdio.h (rewind): Declare. * lib/libc+gnu.c: Update include. * lib/libg.c: Update include. * lib/stub/rewind.c: Remove.
This commit is contained in:
parent
c2b160b58a
commit
5cbe225ddc
|
@ -249,6 +249,7 @@ lib/stdio/fileno.c
|
||||||
lib/stdio/freopen.c
|
lib/stdio/freopen.c
|
||||||
lib/stdio/fscanf.c
|
lib/stdio/fscanf.c
|
||||||
lib/stdio/perror.c
|
lib/stdio/perror.c
|
||||||
|
lib/stdio/rewind.c
|
||||||
lib/stdio/vfscanf.c
|
lib/stdio/vfscanf.c
|
||||||
lib/stdlib/__exit.c
|
lib/stdlib/__exit.c
|
||||||
lib/stdlib/abort.c
|
lib/stdlib/abort.c
|
||||||
|
|
|
@ -79,6 +79,7 @@ int putc (int c, FILE * stream);
|
||||||
int putchar (int c);
|
int putchar (int c);
|
||||||
int puts (char const *s);
|
int puts (char const *s);
|
||||||
int remove (char const *file_name);
|
int remove (char const *file_name);
|
||||||
|
void rewind (FILE * stream);
|
||||||
int setvbuf (FILE * stream, char *buf, int mode, size_t size);
|
int setvbuf (FILE * stream, char *buf, int mode, size_t size);
|
||||||
int snprintf (char *str, size_t size, char const *format, ...);
|
int snprintf (char *str, size_t size, char const *format, ...);
|
||||||
int sprintf (char *str, char const *format, ...);
|
int sprintf (char *str, char const *format, ...);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* -*-comment-start: "//";comment-end:""-*-
|
/* -*-comment-start: "//";comment-end:""-*-
|
||||||
* GNU Mes --- Maxwell Equations of Software
|
* GNU Mes --- Maxwell Equations of Software
|
||||||
* Copyright © 2018 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
* Copyright © 2018,2019 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -18,16 +18,10 @@
|
||||||
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
* along with GNU Mes. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <mes/lib.h>
|
#include <stdio.h>
|
||||||
#include <errno.h>
|
|
||||||
|
|
||||||
int
|
void
|
||||||
rewind (int x)
|
rewind (FILE * stream)
|
||||||
{
|
{
|
||||||
static int stub = 0;
|
fseek (stream, 0, SEEK_SET);
|
||||||
if (__mes_debug () && !stub)
|
|
||||||
eputs ("rewind stub\n");
|
|
||||||
stub = 1;
|
|
||||||
errno = 0;
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue