topology: ctl: fix potential endless loop in tplg_decode_control_enum
The enum decode loop computed size2 = ec->size + ec->priv.size and only
rejected it for being too large (size2 > size). When both ec->size and
ec->priv.size are zero, size2 is zero, which passes that check, and the
loop advances bin/size/pos by zero and loops forever.
Unlike tplg_decode_control_mixer1() and tplg_decode_control_bytes1(),
tplg_decode_control_enum1() never received the computed size and had no
lower-bound size validation. Make it consistent with the mixer/bytes
helpers: pass (bin, size) and reject size < sizeof(*ec). Since the
structure size is non-zero, any accepted element guarantees forward
progress, which eliminates the endless loop.
Closes: https://github.com/alsa-project/alsa-lib/issues/535 Signed-off-by: Jaroslav Kysela <perex@perex.cz>