fbarray: fix init unlock without lock
authorAnatoly Burakov <anatoly.burakov@intel.com>
Fri, 29 Mar 2019 10:57:08 +0000 (10:57 +0000)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 29 Mar 2019 11:49:35 +0000 (12:49 +0100)
commitb8a86c83e0a3bc75cd50562affa6e5df2fbfe0ba
tree268e22a7e34648af90219a4de9850c712e531ca0
parent5a98bc5e83b1562d5b688a3d5a6dd3ee977694d2
fbarray: fix init unlock without lock

Certain failure paths of rte_fbarray_init() will unlock the
mem area lock without locking it first. Fix this by properly
handling the failures.

Fixes: 5b61c62cfd76 ("fbarray: add internal tailq for mapped areas")

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
lib/librte_eal/common/eal_common_fbarray.c