Commit da60639f authored by Changpeng Liu's avatar Changpeng Liu Committed by Tomasz Zawadzki
Browse files

rocksdb: call spdk_app_stop before exit the process



For some other reason when the host didn't have a block
device e.g: "Nvme0n1", we will call exit(1) directly in
the process, the ASAN will report memory leak issue, so
before exiting the process, we call spdk_app_stop to
do the cleanup.

Fix issue #1422.

Change-Id: I7b7a05807625586bd5b97dc31f41e2b86e1b323f
Signed-off-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3586


Community-CI: Mellanox Build Bot
Reviewed-by: default avatarJinYu <jin.yu@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent 6967fec6
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -671,6 +671,7 @@ rocksdb_run(__attribute__((unused)) void *arg1)

	if (bdev == NULL) {
		SPDK_ERRLOG("bdev %s not found\n", g_bdev_name.c_str());
		spdk_app_stop(0);
		exit(1);
	}