From f0fb6c6d4a696da09928c1c319fef0880d6e6035 Mon Sep 17 00:00:00 2001 From: Daniel Verkamp Date: Fri, 23 Sep 2016 11:17:03 -0700 Subject: [PATCH] event: return status code from spdk_app_fini() Change the return type from void to int so that the result of spdk_subsystem_fini() can be reported. Change-Id: I811c25513e41573ca0c9cb111512d7705d107f66 Signed-off-by: Daniel Verkamp --- include/spdk/event.h | 2 +- lib/event/app.c | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/include/spdk/event.h b/include/spdk/event.h index af3e3d13b..7bcbea3b3 100644 --- a/include/spdk/event.h +++ b/include/spdk/event.h @@ -159,7 +159,7 @@ void spdk_app_init(struct spdk_app_opts *opts); /** * \brief Perform final shutdown operations on an application using the event framework. */ -void spdk_app_fini(void); +int spdk_app_fini(void); /** * \brief Start the framework. Once started, the framework will call start_fn on the master diff --git a/lib/event/app.c b/lib/event/app.c index 3c3ab151c..bab54527c 100644 --- a/lib/event/app.c +++ b/lib/event/app.c @@ -405,14 +405,18 @@ spdk_app_init(struct spdk_app_opts *opts) } } -void +int spdk_app_fini(void) { - spdk_subsystem_fini(); + int rc; + + rc = spdk_subsystem_fini(); spdk_trace_cleanup(); spdk_app_remove_pidfile(); spdk_conf_free(g_spdk_app.config); spdk_close_log(); + + return rc; } int