Commit f95dacd5 authored by GangCao's avatar GangCao Committed by Jim Harris
Browse files

bdevperf: explicit destroy the target when failing to alloc resource



The task resource is allocated one by one and when it fails
to allocate at some point, call the explicit destroy to release
the resource.

Change-Id: Ida916ed25a279806fee76104990f1f92daf3e1b6
Signed-off-by: default avatarGangCao <gang.cao@intel.com>
Reviewed-on: https://review.gerrithub.io/393009


Tested-by: default avatarSPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
parent 331af9ea
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -674,6 +674,7 @@ bdevperf_run(void *arg1, void *arg2)

	rc = bdevperf_construct_targets_tasks();
	if (rc) {
		blockdev_heads_destroy();
		spdk_app_stop(1);
		return;
	}