DRAFT lib: setbuf: Fix signature, add prototype.
* lib/stub/setbuf.c (setbuf): Fix signature. * include/stdio.h (setbuf): Add prototype.
This commit is contained in:
parent
fd156286bf
commit
050cc288c3
|
@ -78,6 +78,7 @@ 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);
|
void rewind (FILE * stream);
|
||||||
|
void setbuf (FILE *stream, char *buf);
|
||||||
int setvbuf (FILE * stream, char *buf, int mode, size_t size);
|
int setvbuf (FILE * stream, char *buf, int mode, size_t size);
|
||||||
int ungetc (int c, FILE * stream);
|
int ungetc (int c, FILE * stream);
|
||||||
long ftell (FILE * stream);
|
long ftell (FILE * stream);
|
||||||
|
|
|
@ -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,2022 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
|
||||||
*
|
*
|
||||||
* This file is part of GNU Mes.
|
* This file is part of GNU Mes.
|
||||||
*
|
*
|
||||||
|
@ -20,14 +20,14 @@
|
||||||
|
|
||||||
#include <mes/lib.h>
|
#include <mes/lib.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
int
|
void
|
||||||
setbuf (int x)
|
setbuf (FILE *stream, char *buf)
|
||||||
{
|
{
|
||||||
static int stub = 0;
|
static int stub = 0;
|
||||||
if (__mes_debug () && !stub)
|
if (__mes_debug () && !stub)
|
||||||
eputs ("setbuf stub\n");
|
eputs ("setbuf stub\n");
|
||||||
stub = 1;
|
stub = 1;
|
||||||
errno = 0;
|
errno = 0;
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue