From: Jiwoong Im Date: Wed, 24 Jun 2015 02:41:48 +0000 (+0900) Subject: Fix bug in checking return value of create_cb X-Git-Tag: accepted/tizen/mobile/20150625.054615^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=713e7895fc1c29af744c526d4ddaaacac1bf53d3;p=platform%2Fcore%2Fappfw%2Fapp-core.git Fix bug in checking return value of create_cb call terminate_cb when the create_cb returns false Change-Id: Ib2f455efd01a8dff7debd2cab00c2515a1adbb43 Signed-off-by: Jiwoong Im --- diff --git a/src/appcore-efl.c b/src/appcore-efl.c index e42606c..f704dcb 100644 --- a/src/appcore-efl.c +++ b/src/appcore-efl.c @@ -802,9 +802,11 @@ static int __before_loop(struct ui_priv *ui, int *argc, char ***argv) LOG(LOG_DEBUG, "LAUNCH", "[%s:Platform:appcore_init:done]", ui->name); if (ui->ops && ui->ops->create) { r = ui->ops->create(ui->ops->data); - if (r == -1) { + if (r < 0) { _ERR("create() return error"); appcore_exit(); + if (ui->ops && ui->ops->terminate) + ui->ops->terminate(ui->ops->data); errno = ECANCELED; return -1; }