mirror of
https://github.com/torvalds/linux.git
synced 2024-11-11 06:31:49 +00:00
ALSA: bebob: sizeof() vs ARRAY_SIZE() typo
ARRAY_SIZE() was intended here instead of sizeof(). The "bridgeco_freq_table" array holds integers so the original condition is never true. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewd-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Tested-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
14577c2516
commit
33a5f989de
@ -749,7 +749,7 @@ parse_stream_formation(u8 *buf, unsigned int len,
|
||||
if (buf[2] == bridgeco_freq_table[i])
|
||||
break;
|
||||
}
|
||||
if (i == sizeof(bridgeco_freq_table))
|
||||
if (i == ARRAY_SIZE(bridgeco_freq_table))
|
||||
return -ENOSYS;
|
||||
|
||||
/* Avoid double count by different entries for the same rate. */
|
||||
|
Loading…
Reference in New Issue
Block a user