diff options
author | Emre Ucan <eucan@de.adit-jv.com> | 2015-08-07 15:57:13 +0200 |
---|---|---|
committer | Nobuhiko Tanibata <nobuhiko_tanibata@xddp.denso.co.jp> | 2015-08-17 11:34:06 +0900 |
commit | bac6d0da349ca838a7967c1914f8b6f8880f5172 (patch) | |
tree | 9e7789682a7efb4af56ff4849fa2d7b5e39e3a6a | |
parent | 002b0d41cb0f112e16e33f2fea568585e528a7e9 (diff) | |
download | wayland-ivi-extension-bac6d0da349ca838a7967c1914f8b6f8880f5172.tar.gz |
ilmControl: do nothing if the context is not initialized
Otherwise pthread_join call causes SEGV, beacuse the thread of the ilm_control_context is NULL
Signed-off-by: Emre Ucan <eucan@de.adit-jv.com>
-rw-r--r-- | ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c index 1b44821..03fe870 100644 --- a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c +++ b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c @@ -1139,6 +1139,12 @@ ilmControl_destroy(void) { struct ilm_control_context *ctx = &ilm_context; + if (!ctx->initialized) + { + fprintf(stderr, "[Warning] The ilm_control_context is already destroyed\n"); + return; + } + if (ctx->shutdown_fd > -1) send_shutdown_event(ctx); |