Fix the terminate routine to avoid deadlock in ewk_shutdown 41/106741/3
authorYoungcheol Kang <ychul.kang@samsung.com>
Thu, 22 Dec 2016 16:12:55 +0000 (01:12 +0900)
committerYoungcheol Kang <ychul.kang@samsung.com>
Fri, 23 Dec 2016 00:43:33 +0000 (09:43 +0900)
commitfcf578a4aa5f6359ad8834a11ccc72725b7fb1f2
treebaf576f567eddfa7c8782a1ef68ca85f7779d108
parent932c2606fc8949fda7fdc6d9e07470ac589d1c65
Fix the terminate routine to avoid deadlock in ewk_shutdown

If ewk_shutdown is called when renderer thread works,
the deadlock happens while exiting the web application.

In order to prevent this deadlock problem, crosswalk don't
terminate the web application directly, it terminate
the web application using ewk_view_page_close API.

By using ewk_view_page_close API, crosswalk can receive
the callback that renderer thread was terminated.
After then crosswalk call the ewk_shutdown.

Bug: http://suprem.sec.samsung.net/jira/browse/TSAM-11982

Change-Id: I0d6279be0a03835ab58e2bf21443dcbba286f823
Signed-off-by: Youngcheol Kang <ychul.kang@samsung.com>
runtime/browser/runtime_process.cc
runtime/browser/web_application.cc
runtime/browser/web_application.h