diff options
Diffstat (limited to 'newlib/libc/stdio/viscanf.c')
-rw-r--r-- | newlib/libc/stdio/viscanf.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/newlib/libc/stdio/viscanf.c b/newlib/libc/stdio/viscanf.c index a60c32ff0..9a7d0c5f2 100644 --- a/newlib/libc/stdio/viscanf.c +++ b/newlib/libc/stdio/viscanf.c @@ -127,8 +127,10 @@ _DEFUN(viscanf, (fmt, ap), _CONST char *fmt _AND va_list ap) { - _REENT_SMALL_CHECK_INIT (_REENT); - return __svfiscanf_r (_REENT, _stdin_r (_REENT), fmt, ap); + struct _reent *reent = _REENT; + + _REENT_SMALL_CHECK_INIT (reent); + return __svfiscanf_r (reent, _stdin_r (reent), fmt, ap); } #endif /* !_REENT_ONLY */ |