mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2026-02-22 01:40:08 -05:00
topology: decode: Change declaration of enum decoding function
Size constraints are always checked before invoking tplg_decode_control_enum1. There is no need to validate it twice. Alos moved debug print about size to invoking function, since now it's it responsibility to check size. Signed-off-by: Piotr Maziarz <piotrx.maziarz@linux.intel.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Reviewed-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
56a096ca2c
commit
c32498603a
3 changed files with 7 additions and 17 deletions
|
|
@ -972,8 +972,7 @@ next:
|
|||
err = -EINVAL;
|
||||
goto retval;
|
||||
}
|
||||
err = tplg_decode_control_enum1(tplg, &heap, et, pos,
|
||||
bin, size2);
|
||||
err = tplg_decode_control_enum1(tplg, &heap, et, pos, ec);
|
||||
break;
|
||||
case SND_SOC_TPLG_TYPE_BYTES:
|
||||
bt = tplg_calloc(&heap, sizeof(*bt));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue