mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
Update.
2000-09-01 Ulrich Drepper <drepper@redhat.com> * lockfile.c (__flockfile): If _IO_USER_LOCK bit is set don't do anything. (__funlockfile): Likewise. (__ftrylockfile): If _IO_USER_LOCK bit is set return always 0.
This commit is contained in:
@ -1,3 +1,10 @@
|
|||||||
|
2000-09-01 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* lockfile.c (__flockfile): If _IO_USER_LOCK bit is set don't do
|
||||||
|
anything.
|
||||||
|
(__funlockfile): Likewise.
|
||||||
|
(__ftrylockfile): If _IO_USER_LOCK bit is set return always 0.
|
||||||
|
|
||||||
2000-08-30 Ulrich Drepper <drepper@redhat.com>
|
2000-08-30 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* manager.c (pthread_allocate_stack): Clear descriptor only if not
|
* manager.c (pthread_allocate_stack): Clear descriptor only if not
|
||||||
|
@ -29,7 +29,8 @@ void
|
|||||||
__flockfile (FILE *stream)
|
__flockfile (FILE *stream)
|
||||||
{
|
{
|
||||||
#ifdef USE_IN_LIBIO
|
#ifdef USE_IN_LIBIO
|
||||||
__pthread_mutex_lock (stream->_lock);
|
if ((stream->_flags & _IO_USER_LOCK) == 0)
|
||||||
|
__pthread_mutex_lock (stream->_lock);
|
||||||
#else
|
#else
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -44,7 +45,8 @@ void
|
|||||||
__funlockfile (FILE *stream)
|
__funlockfile (FILE *stream)
|
||||||
{
|
{
|
||||||
#ifdef USE_IN_LIBIO
|
#ifdef USE_IN_LIBIO
|
||||||
__pthread_mutex_unlock (stream->_lock);
|
if ((stream->_flags & _IO_USER_LOCK) == 0)
|
||||||
|
__pthread_mutex_unlock (stream->_lock);
|
||||||
#else
|
#else
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -59,7 +61,10 @@ int
|
|||||||
__ftrylockfile (FILE *stream)
|
__ftrylockfile (FILE *stream)
|
||||||
{
|
{
|
||||||
#ifdef USE_IN_LIBIO
|
#ifdef USE_IN_LIBIO
|
||||||
return __pthread_mutex_trylock (stream->_lock);
|
if ((stream->_flags & _IO_USER_LOCK) == 0)
|
||||||
|
return __pthread_mutex_trylock (stream->_lock);
|
||||||
|
else
|
||||||
|
return 0;
|
||||||
#else
|
#else
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user