mem: fix resize return handling for --single-file-segments
authorJianfeng Tan <jianfeng.tan@intel.com>
Thu, 26 Apr 2018 08:06:53 +0000 (08:06 +0000)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 27 Apr 2018 21:42:40 +0000 (23:42 +0200)
commit5e6df556f60a1b0d94cef1dbbd984186037a9a1a
tree3fbac9d43f461860acdadb124f926a36e656582d
parent3d09a6e26d8b1650c0c55b064c6f8033c65c3a06
mem: fix resize return handling for --single-file-segments

resize_hugefile() returns either 0 (which indicates success) or -1
(which indicates failure). We failed to check the success as we
use --single-file-segments option.

Fixes: 2a04139f66b4 ("eal: add single file segments option")

Signed-off-by: Jianfeng Tan <jianfeng.tan@intel.com>
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
lib/librte_eal/linuxapp/eal/eal_memalloc.c