intel/decoder: fix the possible out of bounds group_iter
authorAndrii Simiklit <andrii.simiklit@globallogic.com>
Mon, 20 Aug 2018 16:20:59 +0000 (19:20 +0300)
committerLionel Landwerlin <lionel.g.landwerlin@intel.com>
Mon, 3 Sep 2018 10:14:30 +0000 (11:14 +0100)
commit095600dad6ee2c93b92026ba9c78ad829a79fcd0
treee9c1779d1af2f0ec77f148f8be321ceb4b6db89e
parent233718a199f96f71f7c0d2063d9a434dc3447d86
intel/decoder: fix the possible out of bounds group_iter

The "gen_group_get_length" function can return a negative value
and it can lead to the out of bounds group_iter.

v2: printing of "unknown command type" was added
v3: just the asserts are added

Signed-off-by: Andrii Simiklit <andrii.simiklit@globallogic.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/intel/common/gen_decoder.c