1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-29 11:41:21 +03:00
* libio/iovdprintf.c (_IO_vdprintf): Set _IO_USER_LOCK flag for
	temporary stream.  Don't define lock.
	* libio/iovsprintf.c: Likewise.
	* libio/iovsnprintf.c: Likewise.
	* libio/iovswprintf.c: Likewise.
	* libio/iovsscanf.c: Likewise.
	* libio/iovswscanf.c: Likewise.
	* stdio-common/vfprintf.c [USE_IN_LIBIO] (buffered_vfprintf): Likewise.
	* libio/genops.c (_IO_no_init): Don't call _IO_lock_init if _lock
	is NULL.
	(_IO_default_finish): Likewise.
	* libio/wgenops.c (_IO_wdefault_finish): Likewise.
This commit is contained in:
Ulrich Drepper
2001-08-11 05:19:24 +00:00
parent 07ba734927
commit c020d48c6e
14 changed files with 48 additions and 70 deletions

View File

@ -111,8 +111,7 @@ _IO_vswprintf (string, maxlen, format, args)
int ret;
struct _IO_wide_data wd;
#ifdef _IO_MTSAFE_IO
_IO_lock_t lock;
sf.f._sbf._f._lock = &lock;
sf.f._sbf._f._lock = NULL;
#endif
if (maxlen == 0)
@ -120,7 +119,7 @@ _IO_vswprintf (string, maxlen, format, args)
length of zero always makes the function fail. */
return -1;
_IO_no_init (&sf.f._sbf._f, 0, 0, &wd, &_IO_wstrn_jumps);
_IO_no_init (&sf.f._sbf._f, _IO_USER_LOCK, 0, &wd, &_IO_wstrn_jumps);
_IO_fwide (&sf.f._sbf._f, 1);
string[0] = L'\0';
_IO_wstr_init_static (&sf.f._sbf._f, string, maxlen - 1, string);