pulse-server: tweak maxlength some more

Make the buffer size at least 4 times as large as the fragment size to avoid
xruns.
This commit is contained in:
Adolfo Rodrigues 2022-07-04 15:56:16 +00:00 committed by Wim Taymans
parent 12bee0edf8
commit 6188e4d074

View file

@ -678,8 +678,8 @@ static uint32_t fix_record_buffer_attr(struct stream *s, struct buffer_attr *att
latency = attr->fragsize; latency = attr->fragsize;
} }
/* make sure can queue at least to fragsize without overruns */ /* make sure can queue at least to fragsize without overruns */
if (attr->maxlength < attr->fragsize * 2) if (attr->maxlength < attr->fragsize * 4)
attr->maxlength = attr->fragsize * 2; attr->maxlength = attr->fragsize * 4;
pw_log_info("[%s] maxlength:%u fragsize:%u minfrag:%u latency:%u", pw_log_info("[%s] maxlength:%u fragsize:%u minfrag:%u latency:%u",
s->client->name, attr->maxlength, attr->fragsize, minfrag, s->client->name, attr->maxlength, attr->fragsize, minfrag,