devargs: fix build with gcc 4.7
authorPablo de Lara <pablo.de.lara.guarch@intel.com>
Mon, 16 Jul 2018 06:26:27 +0000 (07:26 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Wed, 18 Jul 2018 08:36:30 +0000 (10:36 +0200)
commitb7167593e09e67b4746d87ecc390ffff8809599b
treee343497697985661c9950e1b0fcfa772ba4d9563
parentc27dbc300eee78c2eb33e84181617fdd7cbaaae4
devargs: fix build with gcc 4.7

Fixed possible out-of-bounds issue:

lib/librte_eal/common/eal_common_devargs.c:
In function ‘rte_devargs_layers_parse’:
lib/librte_eal/common/eal_common_devargs.c:121:7:
error: array subscript is above array bounds

Bugzilla ID: 71
Fixes: 338327d731e6 ("devargs: add function to parse device layers")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Gaetan Rivet <gaetan.rivet@6wind.com>
lib/librte_eal/common/eal_common_devargs.c