net/mlx5: check memory allocation in flow creation
authorAsaf Penso <asafp@mellanox.com>
Wed, 19 Jun 2019 09:46:24 +0000 (09:46 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 4 Jul 2019 23:52:02 +0000 (01:52 +0200)
commit3f22e3153fb5bd1ae2eebfa77678117eb15b33d8
tree6c40c8f2b2e3a4a21b9afc03c9e9c478113b9b0f
parentcb1d2cce9539f1131a01585888903ab3546d51d9
net/mlx5: check memory allocation in flow creation

rte_calloc functions returns a non-null pointer in case of
success and null pointer in case of failure.

The return value should be checked and the function flow
should take that into consideration.

This patch adds a check for rte_calloc return value in function
flow_list_create.

Fixes: 84c406e74524 ("net/mlx5: add flow translate function")
Cc: stable@dpdk.org
Signed-off-by: Asaf Penso <asafp@mellanox.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>
drivers/net/mlx5/mlx5_flow.c