mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
* sysdeps/unix/sysv/linux/sparc/bits/siginfo.h (struct sigevent):
Add _tid slot to maintain consistency with kernel.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2008-11-17 Nathan Sidwell <nathan@codesourcery.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/sparc/bits/siginfo.h (struct sigevent):
|
||||||
|
Add _tid slot to maintain consistency with kernel.
|
||||||
|
|
||||||
2009-02-04 Ulrich Drepper <drepper@redhat.com>
|
2009-02-04 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* libio/wfileops.c (_IO_wfile_underflow): Fix handling of
|
* libio/wfileops.c (_IO_wfile_underflow): Fix handling of
|
||||||
|
@ -297,14 +297,34 @@ _IO_wfile_underflow (fp)
|
|||||||
|
|
||||||
if (naccbuf == 0)
|
if (naccbuf == 0)
|
||||||
{
|
{
|
||||||
|
if (fp->_IO_read_base < fp->_IO_read_ptr)
|
||||||
|
{
|
||||||
|
/* Partially used the buffer for some input data that
|
||||||
|
produces no output. */
|
||||||
|
size_t avail = fp->_IO_read_end - fp->_IO_read_ptr;
|
||||||
|
memmove (fp->_IO_read_base, fp->_IO_read_ptr, avail);
|
||||||
|
fp->_IO_read_ptr = fp->_IO_read_base;
|
||||||
|
fp->_IO_read_end -= avail;
|
||||||
|
goto again;
|
||||||
|
}
|
||||||
naccbuf = fp->_IO_read_end - fp->_IO_read_ptr;
|
naccbuf = fp->_IO_read_end - fp->_IO_read_ptr;
|
||||||
if (naccbuf >= sizeof (accbuf))
|
if (naccbuf >= sizeof (accbuf))
|
||||||
goto out_eilseq;
|
goto out_eilseq;
|
||||||
|
|
||||||
memcpy (accbuf, fp->_IO_read_ptr, naccbuf);
|
memcpy (accbuf, fp->_IO_read_ptr, naccbuf);
|
||||||
}
|
}
|
||||||
else if (naccbuf == sizeof (accbuf))
|
else
|
||||||
goto out_eilseq;
|
{
|
||||||
|
size_t used = read_ptr_copy - accbuf;
|
||||||
|
if (used > 0)
|
||||||
|
{
|
||||||
|
memmove (accbuf, read_ptr_copy, naccbuf - used);
|
||||||
|
naccbuf -= used;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (naccbuf == sizeof (accbuf))
|
||||||
|
goto out_eilseq;
|
||||||
|
}
|
||||||
|
|
||||||
fp->_IO_read_ptr = fp->_IO_read_end = fp->_IO_read_base;
|
fp->_IO_read_ptr = fp->_IO_read_end = fp->_IO_read_base;
|
||||||
|
|
||||||
|
@ -289,6 +289,10 @@ typedef struct sigevent
|
|||||||
{
|
{
|
||||||
int _pad[__SIGEV_PAD_SIZE];
|
int _pad[__SIGEV_PAD_SIZE];
|
||||||
|
|
||||||
|
/* When SIGEV_SIGNAL and SIGEV_THREAD_ID set, LWP ID of the
|
||||||
|
thread to receive the signal. */
|
||||||
|
__pid_t _tid;
|
||||||
|
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
void (*_function) (sigval_t); /* Function to start. */
|
void (*_function) (sigval_t); /* Function to start. */
|
||||||
|
Reference in New Issue
Block a user