]> git.alsa-project.org Git - alsa-utils.git/commit
aplay: Don't pass most negative integer to abs() in peak calculations
authorTakashi Iwai <tiwai@suse.de>
Tue, 24 Aug 2021 07:58:29 +0000 (09:58 +0200)
committerTakashi Iwai <tiwai@suse.de>
Tue, 24 Aug 2021 07:58:29 +0000 (09:58 +0200)
commitd9b31338153591944d72e62523bad7850b407c63
tree6502ab51d032bfb0cc1c9196cb332f57e4db0719
parent5c4bf63a94ed0c20aca5bafb94ecd05893a45ec1
aplay: Don't pass most negative integer to abs() in peak calculations

The return value from abs() for the most negative integer is
undefined.  Cap it properly for the 32bit sample handling.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
aplay/aplay.c