mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-09 23:00:07 +00:00
libio: Assume _IO_lock_inexpensive
It is already set by both Linux and Hurd.
This commit is contained in:
parent
eaa53d0f77
commit
57094e576a
@ -280,17 +280,10 @@ libc_hidden_proto (_IO_sgetn)
|
||||
# undef _IO_ftrylockfile
|
||||
|
||||
# define _IO_peekc(_fp) _IO_peekc_locked (_fp)
|
||||
# if _IO_lock_inexpensive
|
||||
# define _IO_flockfile(_fp) \
|
||||
# define _IO_flockfile(_fp) \
|
||||
if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_lock_lock (*(_fp)->_lock)
|
||||
# define _IO_funlockfile(_fp) \
|
||||
# define _IO_funlockfile(_fp) \
|
||||
if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_lock_unlock (*(_fp)->_lock)
|
||||
# else
|
||||
# define _IO_flockfile(_fp) \
|
||||
if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_flockfile (_fp)
|
||||
# define _IO_funlockfile(_fp) \
|
||||
if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_funlockfile (_fp)
|
||||
# endif
|
||||
#endif /* _IO_MTSAFE_IO */
|
||||
|
||||
#endif /* _LIBIO_H */
|
||||
|
@ -24,9 +24,6 @@
|
||||
#include <tls.h>
|
||||
#include <lowlevellock.h>
|
||||
|
||||
/* The locking here is very inexpensive, even for inlining. */
|
||||
#define _IO_lock_inexpensive 1
|
||||
|
||||
typedef unsigned int __libc_lock_t;
|
||||
typedef struct
|
||||
{
|
||||
|
@ -23,9 +23,6 @@
|
||||
#include <lowlevellock.h>
|
||||
|
||||
|
||||
/* The locking here is very inexpensive, even for inlining. */
|
||||
#define _IO_lock_inexpensive 1
|
||||
|
||||
typedef struct { int lock; int cnt; void *owner; } _IO_lock_t;
|
||||
#define _IO_lock_t_defined 1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user