mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-05 13:29:57 -05:00
fix module-tunnel.c
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@289 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
ddf9970b8a
commit
a58f248ea5
1 changed files with 4 additions and 1 deletions
|
|
@ -255,8 +255,9 @@ static void stream_get_latency_callback(struct pa_pdispatch *pd, uint32_t comman
|
|||
pa_usec_t buffer_usec, sink_usec, source_usec, transport_usec;
|
||||
int playing;
|
||||
uint32_t queue_length;
|
||||
uint64_t counter;
|
||||
struct timeval local, remote, now;
|
||||
assert(pd && u && t);
|
||||
assert(pd && u);
|
||||
|
||||
if (command != PA_COMMAND_REPLY) {
|
||||
if (command == PA_COMMAND_ERROR)
|
||||
|
|
@ -274,6 +275,7 @@ static void stream_get_latency_callback(struct pa_pdispatch *pd, uint32_t comman
|
|||
pa_tagstruct_getu32(t, &queue_length) < 0 ||
|
||||
pa_tagstruct_get_timeval(t, &local) < 0 ||
|
||||
pa_tagstruct_get_timeval(t, &remote) < 0 ||
|
||||
pa_tagstruct_getu64(t, &counter) < 0 ||
|
||||
!pa_tagstruct_eof(t)) {
|
||||
pa_log(__FILE__": invalid reply.\n");
|
||||
die(u);
|
||||
|
|
@ -322,6 +324,7 @@ static void request_latency(struct userdata *u) {
|
|||
|
||||
gettimeofday(&now, NULL);
|
||||
pa_tagstruct_put_timeval(t, &now);
|
||||
pa_tagstruct_putu64(t, 0);
|
||||
|
||||
pa_pstream_send_tagstruct(u->pstream, t);
|
||||
pa_pdispatch_register_reply(u->pdispatch, tag, DEFAULT_TIMEOUT, stream_get_latency_callback, u);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue