]> git.tuebingen.mpg.de Git - paraslash.git/commit
oss: Avoid sound artefacts on some setups.
authorAndre Noll <maan@tuebingen.mpg.de>
Mon, 8 Sep 2014 20:38:35 +0000 (22:38 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Sun, 21 Sep 2014 11:32:01 +0000 (13:32 +0200)
commit2ba45411ace62b419ce03a085491077deea38878
treea319758979bfb8352b4118822bfbd50428273b83
parent5414dfd4356e63634f1a4e94382d14e200759d18
oss: Avoid sound artefacts on some setups.

Large buffers which result in short writes cause sound artefacts on
certain setups. For example, 22KHz audio on Linux/ALSA in OSS mode
is affected.

This patch caps the number of bytes to write to the maximum possible
value. This value is obtained through the SNDCTL_DSP_GETOSPACE ioctl.
oss_write.c