mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-17 06:59:56 -05:00
core, modules: Remove useless EINTR tests
Since commit ad447d1468 (in 2009) pa_read and pa_write take care of
handling EINTR error.
So, pa_read, pa_write, pa_iochannel_read and pa_iochannel_write can not
exit with errno set to EINTR, and testing it is useless.
This commit is contained in:
parent
8342c12339
commit
05f3e8bf9a
10 changed files with 31 additions and 82 deletions
|
|
@ -1010,7 +1010,7 @@ static int do_read(connection *c) {
|
|||
((uint8_t*) &c->request) + c->read_data_length,
|
||||
sizeof(c->request) - c->read_data_length)) <= 0) {
|
||||
|
||||
if (r < 0 && (errno == EINTR || errno == EAGAIN))
|
||||
if (r < 0 && errno == EAGAIN)
|
||||
return 0;
|
||||
|
||||
pa_log_debug("read(): %s", r < 0 ? pa_cstrerror(errno) : "EOF");
|
||||
|
|
@ -1066,7 +1066,7 @@ static int do_read(connection *c) {
|
|||
(uint8_t*) c->read_data + c->read_data_length,
|
||||
handler->data_length - c->read_data_length)) <= 0) {
|
||||
|
||||
if (r < 0 && (errno == EINTR || errno == EAGAIN))
|
||||
if (r < 0 && errno == EAGAIN)
|
||||
return 0;
|
||||
|
||||
pa_log_debug("read(): %s", r < 0 ? pa_cstrerror(errno) : "EOF");
|
||||
|
|
@ -1097,7 +1097,7 @@ static int do_read(connection *c) {
|
|||
pa_memblock_release(c->scache.memchunk.memblock);
|
||||
|
||||
if (r <= 0) {
|
||||
if (r < 0 && (errno == EINTR || errno == EAGAIN))
|
||||
if (r < 0 && errno == EAGAIN)
|
||||
return 0;
|
||||
|
||||
pa_log_debug("read(): %s", r < 0 ? pa_cstrerror(errno) : "EOF");
|
||||
|
|
@ -1165,7 +1165,7 @@ static int do_read(connection *c) {
|
|||
|
||||
if (r <= 0) {
|
||||
|
||||
if (r < 0 && (errno == EINTR || errno == EAGAIN))
|
||||
if (r < 0 && errno == EAGAIN)
|
||||
return 0;
|
||||
|
||||
pa_log_debug("read(): %s", r < 0 ? pa_cstrerror(errno) : "EOF");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue