blobcli: fix error path for non-CLI mode
This same code with the same test doesn't fail with the rest of 17.10 but was a real problem in script mode on error would call spdk_app_stop() twice. In the unload_bs() path if there's no bs loaded script mode will exit through another code path so don't want to call spdk_app_stop() here. Change-Id: I0175350c7e1a54b4b304b8b184d08076e6e2e0f0 Signed-off-by: Paul Luse <paul.e.luse@intel.com> Reviewed-on: https://review.gerrithub.io/387808 Tested-by: SPDK Automated Test System <sys_sgsw@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
This commit is contained in:
parent
bb28be8adc
commit
a23fa64c83
@ -250,8 +250,9 @@ unload_bs(struct cli_context_t *cli_context, char *msg, int bserrno)
|
||||
cli_context->channel = NULL;
|
||||
}
|
||||
spdk_bs_unload(cli_context->bs, unload_complete, cli_context);
|
||||
} else {
|
||||
} else if (cli_context->cli_mode != CLI_MODE_SCRIPT) {
|
||||
spdk_app_stop(bserrno);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user