Error while executing action flow bulk command
pipeline> p 1 action flow bulk ./config/action.txt
Command "action flow bulk" failed
pipeline>
The flow action entries are added successfully.
But the return value is not computed correctly.
Due to this, the error message appears on CLI.
The return value is computed with rsp->n_flows after rsp pointer is freed.
This fix computes the return value before rsp pointer is freed.
Signed-off-by: Sankar Chokkalingam <sankarx.chokkalingam@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
void **req_entry_ptr;
uint32_t *req_flow_id;
uint32_t i;
+ int status;
/* Check input arguments */
if ((app == NULL) ||
}
/* Read response */
+ status = (rsp->n_flows == n_flows) ? 0 : -1;
/* Commit flows */
for (i = 0; i < rsp->n_flows; i++) {
rte_free(req_flow_id);
rte_free(req_entry_ptr);
- return (rsp->n_flows == n_flows) ? 0 : -1;
+ return status;
}
int