mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-28 05:40:23 -04:00
seq: seq.c - fix calloc arguments
The usage was inverted. The first argument is count of elements, the second one is size of one element. Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
0bb35d4980
commit
305168fd22
1 changed files with 1 additions and 1 deletions
|
|
@ -1356,7 +1356,7 @@ int snd_seq_set_input_buffer_size(snd_seq_t *seq, size_t size)
|
|||
if (size != seq->ibufsize) {
|
||||
char *newbuf;
|
||||
/* use ump event size for avoiding reallocation at switching */
|
||||
newbuf = calloc(sizeof(snd_seq_ump_event_t), size);
|
||||
newbuf = calloc(size, sizeof(snd_seq_ump_event_t));
|
||||
if (newbuf == NULL)
|
||||
return -ENOMEM;
|
||||
free(seq->ibuf);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue