-/* Copyright (C) 1991, 1995, 1996, 1997, 2002, 2004, 2006, 2007
- Free Software Foundation, Inc.
+/* Copyright (C) 1991-2017 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
#include <stdarg.h>
#include <stdio.h>
va_list arg;
int done;
+#ifdef _IO_MTSAFE_IO
_IO_acquire_lock_clear_flags2 (stdin);
+#endif
stdin->_flags2 |= _IO_FLAGS2_SCANF_STD;
va_start (arg, format);
- done = INTUSE(_IO_vfscanf) (stdin, format, arg, NULL);
+ done = _IO_vfscanf (stdin, format, arg, NULL);
va_end (arg);
+#ifdef _IO_MTSAFE_IO
_IO_release_lock (stdin);
+#endif
return done;
}