When ptlrpcd_cpts is used, an array is allocated with parsed
arguments, and then freed before the last user is done with it.
Move freeing to the end of ptlrpcd_init() to fix this.
Test-Parameters: trivial
Fixes:
2686b25c30 ("LU-6325 ptlrpc: make ptlrpcd threads cpt-aware")
Signed-off-by: Oleg Drokin <green@whamcloud.com>
Change-Id: I84847f00ca7df6a9cc56962a09bfe41c1435223e
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/59185
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
ptlrpcds_cpt_idx[cpt] = i;
}
- cfs_expr_list_values_free(cpts, rc);
ncpts = rc;
}
ptlrpcds_num = ncpts;
}
}
out:
+ if (cpts != NULL)
+ cfs_expr_list_values_free(cpts, ncpts);
if (rc != 0)
ptlrpcd_fini();