Try to improve time estimation

This commit is contained in:
João Paulo Rechi Vita 2008-08-15 18:13:25 -03:00 committed by Lennart Poettering
parent 123ba4f5f1
commit 6c10b106d8

View file

@ -642,13 +642,13 @@ filled_up:
* This is the best time to estimate the playback position of the server */
n = u->offset;
//#ifdef SIOCOUTQ
// {
// int l;
// if (ioctl(u->fd, SIOCOUTQ, &l) >= 0 && l > 0)
// n -= l;
// }
//#endif
#ifdef SIOCOUTQ
{
int l;
if (ioctl(u->fd, SIOCOUTQ, &l) >= 0 && l > 0)
n -= l;
}
#endif
usec = pa_bytes_to_usec(n, &u->sink->sample_spec);
if (usec > u->latency)