mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
client-node: improve error reporting
Separate read failure and missed wakeup in 2 messages.
This commit is contained in:
parent
e83bf8a33f
commit
940ff7f53b
1 changed files with 5 additions and 3 deletions
|
|
@ -1083,9 +1083,11 @@ static void node_on_data_fd_events(struct spa_source *source)
|
||||||
if (source->rmask & SPA_IO_IN) {
|
if (source->rmask & SPA_IO_IN) {
|
||||||
uint64_t cmd;
|
uint64_t cmd;
|
||||||
|
|
||||||
if (spa_system_eventfd_read(this->data_system,
|
if (SPA_UNLIKELY(spa_system_eventfd_read(this->data_system,
|
||||||
this->data_source.fd, &cmd) < 0 || cmd != 1)
|
this->data_source.fd, &cmd) < 0))
|
||||||
spa_log_warn(this->log, NAME" %p: read %"PRIu64" failed %m", this, cmd);
|
pw_log_warn(NAME" %p: read failed %m", this);
|
||||||
|
if (SPA_UNLIKELY(cmd > 1))
|
||||||
|
pw_log_warn(NAME" %p: missed %"PRIu64" wakeups", this, cmd - 1);
|
||||||
|
|
||||||
spa_log_trace_fp(this->log, NAME" %p: got ready", this);
|
spa_log_trace_fp(this->log, NAME" %p: got ready", this);
|
||||||
spa_node_call_ready(&this->callbacks, SPA_STATUS_HAVE_DATA);
|
spa_node_call_ready(&this->callbacks, SPA_STATUS_HAVE_DATA);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue