minor cleanups

git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@659 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
Lennart Poettering 2006-04-07 22:45:08 +00:00
parent 7261494b84
commit 4af16e43cb

View file

@ -124,7 +124,7 @@ static void do_write(struct userdata *u) {
continue;
}
pa_log(__FILE__": snd_pcm_writei() failed");
pa_log(__FILE__": snd_pcm_writei() failed: %s", snd_strerror(frames));
return;
}
@ -176,10 +176,12 @@ static pa_usec_t sink_get_latency_cb(pa_sink *s) {
pa_usec_t r = 0;
struct userdata *u = s->userdata;
snd_pcm_sframes_t frames;
int err;
assert(s && u && u->sink);
if (snd_pcm_delay(u->pcm_handle, &frames) < 0) {
pa_log(__FILE__": failed to get delay");
if ((err = snd_pcm_delay(u->pcm_handle, &frames)) < 0) {
pa_log(__FILE__": failed to get delay: %s", snd_strerror(err));
s->get_latency = NULL;
return 0;
}