mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
examples: improve some debug
This commit is contained in:
parent
fef0e17b76
commit
a3ec0cf49e
5 changed files with 11 additions and 7 deletions
|
|
@ -79,8 +79,10 @@ static void on_process(void *userdata)
|
|||
int n_frames, stride;
|
||||
uint8_t *p;
|
||||
|
||||
if ((b = pw_stream_dequeue_buffer(data->stream)) == NULL)
|
||||
if ((b = pw_stream_dequeue_buffer(data->stream)) == NULL) {
|
||||
pw_log_warn("out of buffers: %m");
|
||||
return;
|
||||
}
|
||||
|
||||
buf = b->buffer;
|
||||
if ((p = buf->datas[0].data) == NULL)
|
||||
|
|
|
|||
|
|
@ -100,9 +100,10 @@ on_process(void *_data, struct spa_io_position *position)
|
|||
uint32_t i, j;
|
||||
uint8_t *src, *dst;
|
||||
|
||||
b = pw_filter_dequeue_buffer(data->in_port);
|
||||
if (b == NULL)
|
||||
if ((b = pw_filter_dequeue_buffer(data->in_port)) == NULL) {
|
||||
pw_log_warn("out of buffers: %m");
|
||||
return;
|
||||
}
|
||||
|
||||
buf = b->buffer;
|
||||
|
||||
|
|
|
|||
|
|
@ -104,9 +104,10 @@ on_process(void *_data)
|
|||
uint8_t *src, *dst;
|
||||
bool render_cursor = false;
|
||||
|
||||
b = pw_stream_dequeue_buffer(stream);
|
||||
if (b == NULL)
|
||||
if ((b = pw_stream_dequeue_buffer(stream)) == NULL) {
|
||||
pw_log_warn("out of buffers: %m");
|
||||
return;
|
||||
}
|
||||
|
||||
buf = b->buffer;
|
||||
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ static void on_timeout(void *userdata, uint64_t expirations)
|
|||
pw_log_trace("timeout");
|
||||
|
||||
if ((b = pw_stream_dequeue_buffer(data->stream)) == NULL) {
|
||||
pw_log_warn("out of buffers");
|
||||
pw_log_warn("out of buffers: %m");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ static void on_timeout(void *userdata, uint64_t expirations)
|
|||
pw_log_trace("timeout");
|
||||
|
||||
if ((b = pw_stream_dequeue_buffer(data->stream)) == NULL) {
|
||||
pw_log_warn("out of buffers");
|
||||
pw_log_warn("out of buffers: %m");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue