+12
−7
Loading
Previously, get locking range info will allocate memory everytime. Thus calling this function multiple times will cause memory leak. Now, we allocate only if it is NULL. If it is not, then we just memset to zero. Change-Id: If048416a2056176f86206a33e2b5db210288fe4f Signed-off-by:Chunyang Hui <chunyang.hui@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/472112 Tested-by:
SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by:
Jim Harris <james.r.harris@intel.com> Reviewed-by:
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by:
Changpeng Liu <changpeng.liu@intel.com>