summaryrefslogtreecommitdiff
path: root/aplay
diff options
context:
space:
mode:
authorScott Gilliland <scott.gilliland@gatech.edu>2017-06-23 18:35:03 +0000
committerTakashi Iwai <tiwai@suse.de>2017-06-26 17:05:38 +0200
commita28ff22df8885a3d389901c18c96b45fce9e4fe2 (patch)
tree46497c92d5c359ccd5cae895c38e478124494c77 /aplay
parent1e96c5f50e760f56f7fc53285bfd249ba59a90b5 (diff)
downloadalsa-utils-a28ff22df8885a3d389901c18c96b45fce9e4fe2.tar.gz
aplay: Fix --max-file-time option 32 bits overflow
Fix bug in arecord --max-file-time where the file size could overflow 32 bits. Signed-off-by: Scott Gilliland <scott.gilliland@gatech.edu> Acked-by: John Sauter <John_Sauter@systemeyescomputerstore.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'aplay')
-rw-r--r--aplay/aplay.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/aplay/aplay.c b/aplay/aplay.c
index f793c82..00af662 100644
--- a/aplay/aplay.c
+++ b/aplay/aplay.c
@@ -3027,7 +3027,7 @@ static void capture(char *orig_name)
if (count == 0)
count = LLONG_MAX;
/* compute the number of bytes per file */
- max_file_size = max_file_time *
+ max_file_size = (long long) max_file_time *
snd_pcm_format_size(hwparams.format,
hwparams.rate * hwparams.channels);
/* WAVE-file should be even (I'm not sure), but wasting one byte