diff options
Diffstat (limited to 'newlib/libc/stdio/scanf.c')
-rw-r--r-- | newlib/libc/stdio/scanf.c | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/newlib/libc/stdio/scanf.c b/newlib/libc/stdio/scanf.c index cf1472ba7..5dd14fde4 100644 --- a/newlib/libc/stdio/scanf.c +++ b/newlib/libc/stdio/scanf.c @@ -16,30 +16,31 @@ */ #include <_ansi.h> -#include <reent.h> #include <stdio.h> +#include "local.h" + #ifdef _HAVE_STDC #include <stdarg.h> #else #include <varargs.h> #endif + #include "local.h" #ifndef _REENT_ONLY int #ifdef _HAVE_STDC -scanf(_CONST char *fmt, ...) +scanf (const char *fmt, ...) #else -scanf(fmt, va_alist) - char *fmt; - va_dcl +scanf (fmt, va_alist) + char *fmt; + va_dcl #endif { int ret; va_list ap; - _REENT_SMALL_CHECK_INIT (_REENT); #ifdef _HAVE_STDC va_start (ap, fmt); #else @@ -54,18 +55,17 @@ scanf(fmt, va_alist) int #ifdef _HAVE_STDC -_scanf_r(struct _reent *ptr, _CONST char *fmt, ...) +_scanf_r (struct _reent *ptr, const char *fmt, ...) #else -_scanf_r(ptr, fmt, va_alist) - struct _reent *ptr; - char *fmt; - va_dcl +_scanf_r (ptr, fmt, va_alist) + struct _reent *ptr; + char *fmt; + va_dcl #endif { int ret; va_list ap; - _REENT_SMALL_CHECK_INIT (ptr); #ifdef _HAVE_STDC va_start (ap, fmt); #else @@ -76,3 +76,4 @@ _scanf_r(ptr, fmt, va_alist) return (ret); } + |