From edc95c01e48344ee2d3d6475c43eac1de2c18db9 Mon Sep 17 00:00:00 2001 From: "jaekuk, lee" Date: Thu, 1 Feb 2018 17:44:57 +0900 Subject: [PATCH 01/16] Remove update script Change-Id: I16302cb190e43f9be99179628fdbda902243c417 Signed-off-by: jaekuk, lee --- packaging/crosswalk-tizen.spec | 7 - wrt-upgrade/720.wrt.upgrade.sh | 16 --- wrt-upgrade/wrt-upgrade-info.cc | 171 ----------------------- wrt-upgrade/wrt-upgrade-info.h | 103 -------------- wrt-upgrade/wrt-upgrade.cc | 294 ---------------------------------------- wrt-upgrade/wrt-upgrade.gyp | 38 ------ wrt-upgrade/wrt-upgrade.h | 34 ----- xwalk_tizen.gyp | 1 - 8 files changed, 664 deletions(-) delete mode 100755 wrt-upgrade/720.wrt.upgrade.sh delete mode 100644 wrt-upgrade/wrt-upgrade-info.cc delete mode 100644 wrt-upgrade/wrt-upgrade-info.h delete mode 100755 wrt-upgrade/wrt-upgrade.cc delete mode 100755 wrt-upgrade/wrt-upgrade.gyp delete mode 100644 wrt-upgrade/wrt-upgrade.h mode change 100644 => 100755 xwalk_tizen.gyp diff --git a/packaging/crosswalk-tizen.spec b/packaging/crosswalk-tizen.spec index 9e24101..945b02e 100755 --- a/packaging/crosswalk-tizen.spec +++ b/packaging/crosswalk-tizen.spec @@ -182,7 +182,6 @@ mkdir -p %{buildroot}%{_datadir}/locale mkdir -p %{buildroot}%{_datadir}/icons/xwalk mkdir -p %{buildroot}%{_datadir}/edje/xwalk mkdir -p %{buildroot}%{extension_path} -mkdir -p %{buildroot}%{_datadir}/upgrade/scripts # Loader script file mkdir -p %{buildroot}%{_datadir}/aul/ @@ -226,10 +225,6 @@ install -p -m 755 out/Default/lib/libxwalk_injected_bundle.so %{buildroot}%{_lib # wrt-loader install -p -m 755 out/Default/wrt-loader %{buildroot}%{_bindir} -# wrt-upgrade -install -p -m 755 out/Default/wrt-upgrade %{buildroot}%{_bindir} -install -p -m 644 out/Default/gen/720.wrt.upgrade.sh %{buildroot}%{_datadir}/upgrade/scripts/720.wrt.upgrade.sh - %clean rm -fr %{buildroot} @@ -250,8 +245,6 @@ rm -fr %{buildroot} %attr(755,root,root) %{_bindir}/wrt-client %attr(755,root,root) %{_bindir}/wrt-loader %attr(644,root,root) %{_datadir}/aul/wrt.loader -%attr(755,root,root) %{_bindir}/wrt-upgrade -%attr(755,root,root) %{_datadir}/upgrade/scripts/720.wrt.upgrade.sh %license LICENSE LICENSE.BSD # If it is unified or wearable, create circular-display extension diff --git a/wrt-upgrade/720.wrt.upgrade.sh b/wrt-upgrade/720.wrt.upgrade.sh deleted file mode 100755 index 805a177..0000000 --- a/wrt-upgrade/720.wrt.upgrade.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -PATH=/bin:/usr/bin:/sbin:/usr/sbin - -#excute upgrade application -/usr/bin/wrt-upgrade - -#remove unuse databases -rm /opt/dbspace/.wrt.db -rm /opt/dbspace/.wrt.db-journal - -rm -r /opt/share/widget - -rm /opt/usr/dbspace/.wrt_custom_handler.db -rm /opt/usr/dbspace/.wrt_custom_handler.db-journal -rm /opt/usr/dbspace/.wrt_i18n.db -rm /opt/usr/dbspace/.wrt_i18n.db-journal diff --git a/wrt-upgrade/wrt-upgrade-info.cc b/wrt-upgrade/wrt-upgrade-info.cc deleted file mode 100644 index ca905fe..0000000 --- a/wrt-upgrade/wrt-upgrade-info.cc +++ /dev/null @@ -1,171 +0,0 @@ -// Copyright (c) 2013 Intel Corporation. All rights reserved. -// Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "wrt-upgrade/wrt-upgrade-info.h" -#include "common/logger.h" - -// #include - -namespace { -const std::string kSectionPrefix = "_SECT_"; -const std::string kSectionSuffix = "_SECT_"; - -const std::string kDBPublicSection = "public"; -const std::string kDBPrivateSection = "private"; - -const std::string kGeolocationPermissionPrefix = "__WRT_GEOPERM_"; -const std::string kNotificationPermissionPrefix = "__WRT_NOTIPERM_"; -const std::string kQuotaPermissionPrefix = "__WRT_QUOTAPERM_"; -const std::string kCertificateAllowPrefix = "__WRT_CERTIPERM_"; -const std::string kUsermediaPermissionPrefix = "__WRT_USERMEDIAPERM_"; - -const std::string kValueAllow = "allowed"; -const std::string kValueDenied = "denied"; -const std::string kValueUnknown = "unknown"; - -const std::string kAppDirectoryPrefix = "/opt/usr/home/owner/apps_rw/"; -const std::string kAppSecurityOriginDBFile = "/data/.security_origin.db"; -const std::string kAppCertificateDBFile = "/data/.certificate.db"; - -enum { - FEATURE_GEOLOCATION = 0, - FEATURE_WEB_NOTIFICATION, - FEATURE_USER_MEDIA, - FEATURE_FULLSCREEN_MODE, - FEATURE_WEB_DATABASE, - FEATURE_CAMERA, - FEATURE_AUDIO_RECORDER -}; -enum { - RESULT_UNKNOWN = 0, - RESULT_ALLOW_ONCE, - RESULT_DENY_ONCE, - RESULT_ALLOW_ALWAYS, - RESULT_DENY_ALWAYS -}; -} // namespace - -namespace upgrade { - -PreferenceInfo::PreferenceInfo(std::string key, std::string value) { - m_section_ = kDBPublicSection; - m_key_ = key; - m_value_ = value; -} -SecurityOriginInfo::SecurityOriginInfo( - int feature, - std::string scheme, - std::string host, - int port, - int result) { - m_section_ = kDBPrivateSection; - m_key_ = translateKey(feature, scheme, host, port); - m_value_ = translateValue(result); -} -std::string SecurityOriginInfo::translateKey( - int feature, - std::string scheme, - std::string host, - int port) { - - std::string key = ""; - - switch (feature) { - case FEATURE_GEOLOCATION : - key += kGeolocationPermissionPrefix; - break; - case FEATURE_WEB_NOTIFICATION : - key += kNotificationPermissionPrefix; - break; - case FEATURE_USER_MEDIA : - key += kUsermediaPermissionPrefix; - break; - case FEATURE_WEB_DATABASE : - key += kQuotaPermissionPrefix; - break; - default : - break; - } - - key += scheme; - key += "://"; - key += host; - key += ":"; - key += std::to_string(port); - - return key; -} -std::string SecurityOriginInfo::translateValue(int result) { - std::string value = ""; - - switch (result) { - case RESULT_ALLOW_ALWAYS : - value = kValueAllow; - break; - case RESULT_DENY_ALWAYS : - value = kValueDenied; - break; - case RESULT_UNKNOWN : - case RESULT_ALLOW_ONCE : - case RESULT_DENY_ONCE : - default : - value = kValueUnknown; - break; - } - return value; -} -CertificateInfo::CertificateInfo( - std::string pem, - int result) { - m_section_ = kDBPrivateSection; - m_key_ = translateKey(pem); - m_value_ = translateValue(result); -} -std::string CertificateInfo::translateKey(std::string pem) { - std::string key = ""; - key = kCertificateAllowPrefix + pem; - return key; -} -std::string CertificateInfo::translateValue(int result) { - std::string value = ""; - - switch (result) { - case RESULT_ALLOW_ALWAYS : - value = kValueAllow; - break; - case RESULT_DENY_ALWAYS : - value = kValueDenied; - break; - case RESULT_UNKNOWN : - case RESULT_ALLOW_ONCE : - case RESULT_DENY_ONCE : - default : - value = kValueUnknown; - break; - } - return value; -} -WrtUpgradeInfo::WrtUpgradeInfo(std::string appid) { - app_id_ = appid; - pkg_id_ = appid.substr(0, appid.find_first_of('.')); - app_dir_ = kAppDirectoryPrefix + pkg_id_; -} -void WrtUpgradeInfo::addPreferenceInfo(PreferenceInfo preference) { - preference_info_list_.push_back(preference); -} -void WrtUpgradeInfo::addSecurityOriginInfo(SecurityOriginInfo security_origin) { - security_origin_info_list_.push_back(security_origin); -} -void WrtUpgradeInfo::addCertificateInfo(CertificateInfo certificate) { - certificate_info_list.push_back(certificate); -} - -std::string WrtUpgradeInfo::getSecurityOriginDB() { - return app_dir_ + kAppSecurityOriginDBFile; -} -std::string WrtUpgradeInfo::getCertificateDB() { - return app_dir_ + kAppCertificateDBFile; -} -} // namespace upgrade diff --git a/wrt-upgrade/wrt-upgrade-info.h b/wrt-upgrade/wrt-upgrade-info.h deleted file mode 100644 index c304e62..0000000 --- a/wrt-upgrade/wrt-upgrade-info.h +++ /dev/null @@ -1,103 +0,0 @@ -// Copyright (c) 2013 Intel Corporation. All rights reserved. -// Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef WRT_UPGRADE_INFO_H -#define WRT_UPGRADE_INFO_H - -#include -#include -#include - -namespace upgrade { -class PreferenceInfo{ - public: - PreferenceInfo(std::string key, std::string value); - std::string getSection() {return m_section_;} - std::string getKey() {return m_key_;} - std::string getValue() {return m_value_;} - private: - std::string m_section_; - std::string m_key_; - std::string m_value_; -}; - -class SecurityOriginInfo{ - public: - SecurityOriginInfo( - int feature, - std::string scheme, - std::string host, - int port, - int result); - std::string getSection() {return m_section_;} - std::string getKey() {return m_key_;} - std::string getValue() {return m_value_;} - private: - std::string translateKey( - int feature, - std::string scheme, - std::string host, - int port); - std::string translateValue(int result); - std::string m_section_; - std::string m_key_; - std::string m_value_; -}; - -class CertificateInfo{ - public: - CertificateInfo( - std::string pem, - int result); - std::string getSection() {return m_section_;} - std::string getKey() {return m_key_;} - std::string getValue() {return m_value_;} - private: - std::string translateKey(std::string pem); - std::string translateValue(int result); - std::string m_section_; - std::string m_key_; - std::string m_value_; -}; - -class WrtUpgradeInfo{ - public: - WrtUpgradeInfo() {} - explicit WrtUpgradeInfo(std::string appid); - - std::string getAppid() { return app_id_; } - std::string getPkgid() { return pkg_id_; } - std::string getAppDir() { return app_dir_; } - std::string getSecurityOriginDB(); - std::string getCertificateDB(); - - void addPreferenceInfo(PreferenceInfo preference); - void addSecurityOriginInfo(SecurityOriginInfo security_origin); - void addCertificateInfo(CertificateInfo certificate); - - PreferenceInfo getPreferenceInfo(int idx) - {return preference_info_list_[idx];} - SecurityOriginInfo getSecurityOriginInfo(int idx) - {return security_origin_info_list_[idx];} - CertificateInfo getCertificateInfo(int idx) - {return certificate_info_list[idx];} - - int getPreferenceInfoSize() - {return static_cast(preference_info_list_.size());} - int getSecurityOriginInfoSize() - {return static_cast(security_origin_info_list_.size());} - int getCertificateInfoSize() - {return static_cast(certificate_info_list.size());} - - private: - std::string pkg_id_; - std::string app_id_; - std::string app_dir_; - std::vector preference_info_list_; - std::vector security_origin_info_list_; - std::vector certificate_info_list; -}; -} // namespace upgrade -#endif // WRT_UPGRADE_INFO_H diff --git a/wrt-upgrade/wrt-upgrade.cc b/wrt-upgrade/wrt-upgrade.cc deleted file mode 100755 index 43e7ea4..0000000 --- a/wrt-upgrade/wrt-upgrade.cc +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright (c) 2013 Intel Corporation. All rights reserved. -// Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "wrt-upgrade/wrt-upgrade.h" - -#include -#include - -#include -#include -#include - -#include "common/picojson.h" -#include "common/logger.h" -#include "common/file_utils.h" - -namespace { - const std::string kWRTDbFile = "/opt/dbspace/.wrt.db"; - const std::string kAppDirectoryPrefix = "/opt/usr/home/owner/apps_rw/"; - const std::string kAppMigrationFile = "/data/.runtime.migration"; - const std::string kJournalPostfix = "-journal"; -} // namespace - -namespace upgrade { -WrtUpgrade::WrtUpgrade() { -} -WrtUpgrade::~WrtUpgrade() { -} -void WrtUpgrade::Run() { - ParseWrtDatabse(); - ParseSecurityOriginDatabase(); - ParseCertificatenDatabase(); - CreateMigrationFile(); - RemoveDatabases(); -} -void WrtUpgrade::ParseWrtDatabse() { - std::cout << "parseWrtDatabse" << std::endl; - sqlite3 *wrt_db; - try { - int ret = sqlite3_open(kWRTDbFile.c_str(), &wrt_db); - if (ret != SQLITE_OK) { - throw("error to open wrt database"); - } - - // get applist - std::string query = "select tizen_appid from widgetinfo"; - sqlite3_stmt* stmt = NULL; - - ret = sqlite3_prepare_v2(wrt_db, query.c_str() , -1, &stmt, NULL); - if (ret != SQLITE_OK) { - throw("error for prepare query"); - } - - while (SQLITE_ROW == sqlite3_step(stmt)) { - std::string appid - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 0))); - application_list_.push_back(appid); - application_map_.insert( - std::pair(appid, WrtUpgradeInfo(appid))); - } - - ret = sqlite3_finalize(stmt); - if (ret != SQLITE_OK) { - throw("error for finalize stmt"); - } - - // get widget preference - query = "select tizen_appid,key_name,key_value from widgetpreference"; - stmt = NULL; - - ret = sqlite3_prepare_v2(wrt_db, query.c_str() , -1, &stmt, NULL); - if (ret != SQLITE_OK) { - throw("error for prepare query"); - } - - while (SQLITE_ROW == sqlite3_step(stmt)) { - std::string appid - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 0))); - std::string key - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 1))); - std::string value - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 2))); - - application_map_[appid].addPreferenceInfo(PreferenceInfo(key, value)); - } - ret = sqlite3_finalize(stmt); - if (ret != SQLITE_OK) { - throw("error for finalize stmt"); - } - } catch(const char* err) { - std::cout << err << std::endl; - } - sqlite3_close(wrt_db); -} -void WrtUpgrade::ParseSecurityOriginDatabase() { - std::cout << "parseSecurityOriginDatabase" << std::endl; - for (int i = 0; i < static_cast(application_list_.size()) ; i++) { - sqlite3 *security_origin_db; - std::string appid = application_list_[i]; - try { - std::string db_path = application_map_[appid].getSecurityOriginDB(); - - if (access(db_path.c_str(), 0) != 0) { - throw("file is not exist : ["+db_path+"]"); - } - int ret = sqlite3_open(db_path.c_str(), &security_origin_db); - if (ret != SQLITE_OK) { - throw("error to open wrt database"); - } - - // get applist - std::string query = "select * from securityorigininfo"; - sqlite3_stmt* stmt = NULL; - - ret = sqlite3_prepare_v2( - security_origin_db, query.c_str() , -1, &stmt, NULL); - if (ret != SQLITE_OK) { - throw("error for prepare query"); - } - - while (SQLITE_ROW == sqlite3_step(stmt)) { - int feature = sqlite3_column_int(stmt, 0); - std::string scheme - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 1))); - std::string host - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 2))); - int port = sqlite3_column_int(stmt, 3); - int result = sqlite3_column_int(stmt, 4); - application_map_[appid].addSecurityOriginInfo( - SecurityOriginInfo(feature, scheme, host, port, result)); - } - - ret = sqlite3_finalize(stmt); - if (ret != SQLITE_OK) { - throw("error for finalize stmt"); - } - } catch(...) { - } - sqlite3_close(security_origin_db); - } -} -void WrtUpgrade::ParseCertificatenDatabase() { - std::cout << "parseCertificateDatabase" << std::endl; - for (int i = 0 ; i < static_cast(application_list_.size()) ; i++) { - sqlite3 *certificate_db; - std::string appid = application_list_[i]; - try { - std::string db_path = application_map_[appid].getCertificateDB(); - - if (access(db_path.c_str(), 0) != 0) { - throw("file is not exist : ["+db_path+"]"); - } - int ret = sqlite3_open(db_path.c_str(), &certificate_db); - if (ret != SQLITE_OK) { - throw("error to open wrt database"); - } - - // get applist - std::string query = "select * from certificateinfo"; - sqlite3_stmt* stmt = NULL; - - ret = sqlite3_prepare_v2(certificate_db, query.c_str() , -1, &stmt, NULL); - if (ret != SQLITE_OK) { - throw("error for prepare query"); - } - - while (SQLITE_ROW == sqlite3_step(stmt)) { - std::string certificate - = std::string(reinterpret_cast( - sqlite3_column_text(stmt, 0))); - int result = sqlite3_column_int(stmt, 1); - application_map_[appid].addCertificateInfo( - CertificateInfo(certificate, result)); - } - - ret = sqlite3_finalize(stmt); - if (ret != SQLITE_OK) { - throw("error for finalize stmt"); - } - } catch(...) { - } - sqlite3_close(certificate_db); - } -} -void WrtUpgrade::CreateMigrationFile() { - std::cout << "createMigrationFile" << std::endl; - for (int i = 0 ; i < static_cast(application_list_.size()) ; i++) { - std::string appid = application_list_[i]; - std::string json_str = CreateJsonObject(appid); - if (!json_str.empty()) { - std::string pkg_id = appid.substr(0, appid.find_first_of('.')); - std::string output_file_path - = kAppDirectoryPrefix + pkg_id + kAppMigrationFile; - std::ofstream output_file(output_file_path); - output_file << json_str; - output_file.close(); - } - } -} -void WrtUpgrade::RemoveDatabases() { - for (int i = 0 ; i < static_cast(application_list_.size()) ; i++) { - std::string appid = application_list_[i]; - try { - std::string security_origin_db_path - = application_map_[appid].getSecurityOriginDB(); - std::string security_origin_journal_db_path - = security_origin_db_path + kJournalPostfix; - std::string certificate_db_path - = application_map_[appid].getCertificateDB(); - std::string certificate_journal_db_path - = certificate_db_path + kJournalPostfix; - - RemoveFile(security_origin_db_path); - RemoveFile(security_origin_journal_db_path); - RemoveFile(certificate_db_path); - RemoveFile(certificate_journal_db_path); - } catch(...) { - } - } -} -std::string WrtUpgrade::CreateJsonObject(std::string appid) { - WrtUpgradeInfo info = application_map_[appid]; - - if (info.getPreferenceInfoSize() == 0 - && info.getSecurityOriginInfoSize() == 0 - && info.getCertificateInfoSize() == 0) { - return ""; - } - std::cout << "createJsonObject for " << appid << std::endl; - - // make preference value arr : vector - picojson::array preference_arr; - for (int i = 0 ; i < info.getPreferenceInfoSize() ; i++) { - PreferenceInfo p_info = info.getPreferenceInfo(i); - picojson::object obj; - obj["key"] = picojson::value(p_info.getKey()); - obj["value"] = picojson::value(p_info.getValue()); - preference_arr.push_back(picojson::value(obj)); - } - - // make security_origin value arr : vector - picojson::array securityorigin_arr; - for (int i = 0 ; i < info.getSecurityOriginInfoSize() ; i++) { - SecurityOriginInfo s_info = info.getSecurityOriginInfo(i); - picojson::object obj; - obj["section"] = picojson::value(s_info.getSection()); - obj["key"] = picojson::value(s_info.getKey()); - obj["value"] = picojson::value(s_info.getValue()); - securityorigin_arr.push_back(picojson::value(obj)); - } - - // make certificate value arr : vector - picojson::array certificate_arr; - for (int i = 0 ; i < info.getCertificateInfoSize() ; i++) { - CertificateInfo c_info = info.getCertificateInfo(i); - picojson::object obj; - obj["section"] = picojson::value(c_info.getSection()); - obj["key"] = picojson::value(c_info.getKey()); - obj["value"] = picojson::value(c_info.getValue()); - certificate_arr.push_back(picojson::value(obj)); - } - - // make one json - picojson::object migration_obj; - migration_obj["preference"] = picojson::value(preference_arr); - migration_obj["security_orgin"] = picojson::value(securityorigin_arr); - migration_obj["certificate"] = picojson::value(certificate_arr); - - picojson::value migration_val = picojson::value(migration_obj); - std::string json_str = migration_val.serialize(); - return json_str; -} -bool WrtUpgrade::RemoveFile(const std::string& path) { - if (!common::utils::Exists(path)) { - LOGGER(ERROR) << "File is not Exist : " << path; - return false; - } - return (remove(path.c_str()) == 0); -} -} // namespace upgrade -int main() { - std::cout << "Tizen database migration tool for Webruntime" << std::endl; - upgrade::WrtUpgrade mt; - mt.Run(); - return 0; -} diff --git a/wrt-upgrade/wrt-upgrade.gyp b/wrt-upgrade/wrt-upgrade.gyp deleted file mode 100755 index 55b48a6..0000000 --- a/wrt-upgrade/wrt-upgrade.gyp +++ /dev/null @@ -1,38 +0,0 @@ -{ - 'includes': [ - '../build/common.gypi', - ], - 'targets': [ - { - 'target_name': 'wrt-upgrade', - 'type': 'executable', - 'dependencies': [ - '../common/common.gyp:xwalk_tizen_common', - ], - 'sources': [ - 'wrt-upgrade.cc', - 'wrt-upgrade-info.cc', - ], - 'ldflags': [ - '-pie', - ], - 'variables': { - 'packages': [ - 'sqlite3', - 'dlog', - ], - }, - 'libraries' : [ - '-ldl', - ], - 'copies': [ - { - 'destination': '<(SHARED_INTERMEDIATE_DIR)', - 'files': [ - '720.wrt.upgrade.sh' - ], - }, - ], - }, # end of target 'wrt-upgrade' - ], # end of targets -} diff --git a/wrt-upgrade/wrt-upgrade.h b/wrt-upgrade/wrt-upgrade.h deleted file mode 100644 index 110cf46..0000000 --- a/wrt-upgrade/wrt-upgrade.h +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright (c) 2013 Intel Corporation. All rights reserved. -// Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef WRT_UPGRADE_H -#define WRT_UPGRADE_H -#include -#include -#include -#include - -#include "wrt-upgrade/wrt-upgrade-info.h" - -namespace upgrade { -class WrtUpgrade{ - public: - WrtUpgrade(); - ~WrtUpgrade(); - void Run(); - private: - void ParseWrtDatabse(); - void ParseSecurityOriginDatabase(); - void ParseCertificatenDatabase(); - void CreateMigrationFile(); - void RemoveDatabases(); - bool RemoveFile(const std::string& path); - void RedirectSymlink(); - std::string CreateJsonObject(std::string appid); - std::vector application_list_; - std::map application_map_; -}; -} // namespace upgrade -#endif // WRT_UPGRADE_H diff --git a/xwalk_tizen.gyp b/xwalk_tizen.gyp old mode 100644 new mode 100755 index 94dea57..4c6f3a9 --- a/xwalk_tizen.gyp +++ b/xwalk_tizen.gyp @@ -8,7 +8,6 @@ 'extensions/extensions.gyp:*', 'runtime/runtime.gyp:*', 'loader/loader.gyp:*', - 'wrt-upgrade/wrt-upgrade.gyp:*', ], }, # end of target 'xwalk_tizen' ], # end of targets -- 2.7.4 From ef9c335dc3bd7da0bc66135576e52915aa1d03b0 Mon Sep 17 00:00:00 2001 From: "pr.jung" Date: Thu, 8 Mar 2018 15:07:23 +0900 Subject: [PATCH 02/16] Change deprecated internal api to public api - libdeviced haptic apis are deprecated - Changed to use capi-system-device apis Change-Id: I7c592774f379620aec1ddae9a60f43cb0694c6ef Signed-off-by: pr.jung --- packaging/crosswalk-tizen.spec | 2 +- runtime/browser/vibration_manager.cc | 12 ++++++------ runtime/runtime.gyp | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packaging/crosswalk-tizen.spec b/packaging/crosswalk-tizen.spec index 945b02e..0c24483 100755 --- a/packaging/crosswalk-tizen.spec +++ b/packaging/crosswalk-tizen.spec @@ -31,7 +31,7 @@ BuildRequires: pkgconfig(capi-system-info) BuildRequires: pkgconfig(capi-ui-efl-util) BuildRequires: pkgconfig(chromium-efl) >= 56.0.0, pkgconfig(chromium-efl) < 57.0.0 BuildRequires: pkgconfig(cynara-client) -BuildRequires: pkgconfig(deviced) +BuildRequires: pkgconfig(capi-system-device) BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(ecore) BuildRequires: pkgconfig(efl-extension) diff --git a/runtime/browser/vibration_manager.cc b/runtime/browser/vibration_manager.cc index 0e6cfcd..301b20c 100755 --- a/runtime/browser/vibration_manager.cc +++ b/runtime/browser/vibration_manager.cc @@ -16,7 +16,7 @@ #include "runtime/browser/vibration_manager.h" -#include +#include #include "common/logger.h" @@ -42,7 +42,7 @@ VibrationImpl::VibrationImpl() VibrationImpl::~VibrationImpl() { if (handle_ != 0) { - haptic_close(handle_); + device_haptic_close(handle_); handle_ = 0; } } @@ -51,8 +51,8 @@ bool VibrationImpl::Initialize() { if (handle_ != 0) return true; - int ret = haptic_open(HAPTIC_DEVICE_0, &handle_); - if (ret != HAPTIC_ERROR_NONE) { + int ret = device_haptic_open(0, &handle_); + if (ret != DEVICE_ERROR_NONE) { LOGGER(ERROR) << "Fail to open haptic device"; handle_ = 0; return false; @@ -62,13 +62,13 @@ bool VibrationImpl::Initialize() { void VibrationImpl::Start(int ms) { if (Initialize()) { - haptic_vibrate_monotone(handle_, ms, NULL); + device_haptic_vibrate(handle_, ms, 100, NULL); } } void VibrationImpl::Stop() { if (Initialize()) { - haptic_stop_all_effects(handle_); + device_haptic_stop(handle_, NULL); } } diff --git a/runtime/runtime.gyp b/runtime/runtime.gyp index ce48619..5772a35 100755 --- a/runtime/runtime.gyp +++ b/runtime/runtime.gyp @@ -57,7 +57,7 @@ 'ecore', 'elementary', 'efl-extension', - 'deviced', + 'capi-system-device', 'manifest-parser', 'wgt-manifest-handlers', 'notification', -- 2.7.4 From ab4588210688e487921bf1230bffaa0625ae7fc4 Mon Sep 17 00:00:00 2001 From: Jaehun Jeong Date: Thu, 15 Mar 2018 13:32:13 +0900 Subject: [PATCH 03/16] Add -Wprint-abs-path to generate absolute path for buildwarnings Change-Id: I9413df09e4e65ee23d73e43b0b897556c579b27e Signed-off-by: Jaehun Jeong --- build/common.gypi | 1 + 1 file changed, 1 insertion(+) diff --git a/build/common.gypi b/build/common.gypi index ec6b82a..4954e2f 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -45,6 +45,7 @@ '-fPIC', '-fvisibility=hidden', '-Wall', + '-Wprint-abs-path', ], 'libraries' : [ '-L./lib', -- 2.7.4 From 7f35bd8eab7cdae3093e4644b74b5aa724db34e5 Mon Sep 17 00:00:00 2001 From: "min7.choi" Date: Mon, 19 Mar 2018 13:46:11 +0900 Subject: [PATCH 04/16] Remove Ecore-wayland dependency (missing code) commit id : 46c3f83ce40d25c0816ca703221fafd8dcfb051e There was a missing part, so I deleted it. : runtime/browser/splash_screen.cc Change-Id: I068dcd612fea49a0263da4d17399dbed9784b01e Signed-off-by: min7.choi --- runtime/browser/splash_screen.cc | 1 - 1 file changed, 1 deletion(-) diff --git a/runtime/browser/splash_screen.cc b/runtime/browser/splash_screen.cc index f588258..fe86062 100755 --- a/runtime/browser/splash_screen.cc +++ b/runtime/browser/splash_screen.cc @@ -20,7 +20,6 @@ #include #include -#include #include #include "common/logger.h" -- 2.7.4 From f7812984aebaadb7111afbd784edf2627968f2b8 Mon Sep 17 00:00:00 2001 From: mallikarjun82 Date: Wed, 4 Apr 2018 19:22:32 +0530 Subject: [PATCH 05/16] coverity error handling This patch initializes variables to prevent from having garbage values. Coverity: 108757, 107570, 107274, 105091 Change-Id: If0ea245e771508a92f75d897049c9a7ede97e5db Signed-off-by: mallikarjun82 --- common/url.cc | 5 ++++- extensions/common/xwalk_extension_server.cc | 3 ++- runtime/browser/native_window.cc | 3 ++- runtime/browser/web_view_impl.cc | 2 ++ 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/common/url.cc b/common/url.cc index 898190c..4a91a95 100644 --- a/common/url.cc +++ b/common/url.cc @@ -54,7 +54,7 @@ int GetDefaultPort(const std::string& scheme) { class URLImpl { public: explicit URLImpl(const std::string& url); - URLImpl() {} + URLImpl(); std::string url() const { return url_; } std::string scheme() const { return scheme_; } @@ -75,6 +75,9 @@ class URLImpl { void ExtractPath(); }; +URLImpl::URLImpl() : port_(0) { +} + URLImpl::URLImpl(const std::string& url) : port_(0) { if (url.empty()) return; diff --git a/extensions/common/xwalk_extension_server.cc b/extensions/common/xwalk_extension_server.cc index fc50396..e895ce8 100755 --- a/extensions/common/xwalk_extension_server.cc +++ b/extensions/common/xwalk_extension_server.cc @@ -22,7 +22,8 @@ XWalkExtensionServer* XWalkExtensionServer::GetInstance() { return &self; } -XWalkExtensionServer::XWalkExtensionServer() { +XWalkExtensionServer::XWalkExtensionServer() + : ewk_context_(nullptr){ manager_.LoadExtensions(); } diff --git a/runtime/browser/native_window.cc b/runtime/browser/native_window.cc index 1f2fde2..5bbbc4d 100755 --- a/runtime/browser/native_window.cc +++ b/runtime/browser/native_window.cc @@ -79,7 +79,8 @@ NativeWindow::NativeWindow() progressbar_(NULL), top_layout_(NULL), rotation_(0), - handler_id_(0) { + handler_id_(0), + natural_orientation_(ScreenOrientation::LANDSCAPE_PRIMARY) { } NativeWindow::~NativeWindow() { diff --git a/runtime/browser/web_view_impl.cc b/runtime/browser/web_view_impl.cc index 01050c5..83a5356 100755 --- a/runtime/browser/web_view_impl.cc +++ b/runtime/browser/web_view_impl.cc @@ -923,6 +923,8 @@ void WebViewImpl::InitEditorClientImeCallback() { SoftKeyboardChangeEventValue softkeyboard_value; softkeyboard_value.state = "off"; + softkeyboard_value.width = 0; + softkeyboard_value.height = 0; self->listener_->OnSoftKeyboardChangeEvent(self->view_, softkeyboard_value); }; -- 2.7.4 From 9c2dca408f868502c0e430b29c8313682601eea3 Mon Sep 17 00:00:00 2001 From: mallikarjun82 Date: Tue, 3 Apr 2018 20:17:56 +0530 Subject: [PATCH 06/16] coverity error handling This patch initializes uninitialized member variable. Coverity:110284, 107447 Change-Id: Ia5f214e0a286b8e4a75822b3c4e62f96301d52b1 Signed-off-by: mallikarjun82 --- common/app_control.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/common/app_control.cc b/common/app_control.cc index ce625e9..8fbe4e8 100755 --- a/common/app_control.cc +++ b/common/app_control.cc @@ -107,12 +107,14 @@ static void AppendExtraDatafromUrl(AppControl* request, } // namespace -AppControl::AppControl(app_control_h app_control) { +AppControl::AppControl(app_control_h app_control) + : app_control_bundle_(nullptr){ app_control_clone(&app_control_, app_control); app_control_to_bundle(app_control_, &app_control_bundle_); } -AppControl:: AppControl() { +AppControl:: AppControl() + : app_control_bundle_(nullptr){ app_control_create(&app_control_); app_control_to_bundle(app_control_, &app_control_bundle_); } -- 2.7.4 From 7584fad13ff5f760a294579fec4c0b1a18f74ceb Mon Sep 17 00:00:00 2001 From: mallikarjun82 Date: Tue, 3 Apr 2018 19:47:02 +0530 Subject: [PATCH 07/16] coverity error handling This patch initialized member variable in constructor. Coverity:111022 Change-Id: I299d16289809c9a743dee74d18d39e0dd80d56c3 Signed-off-by: mallikarjun82 --- common/application_data.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/common/application_data.cc b/common/application_data.cc index b25d347..a205ecc 100755 --- a/common/application_data.cc +++ b/common/application_data.cc @@ -45,6 +45,7 @@ const char* kWearableClockCategory = "http://tizen.org/category/wearable_clock"; ApplicationData::ApplicationData(const std::string& appid) : app_id_(appid), + app_type_(UI), loaded_(false) { SCOPE_PROFILE(); char* res_path = app_get_resource_path(); -- 2.7.4 From 44d9d87dfd3663d0e073a2ec461881382559da55 Mon Sep 17 00:00:00 2001 From: "surya.kumar7" Date: Fri, 6 Apr 2018 19:57:38 +0530 Subject: [PATCH 08/16] Coverity error handling This patch handles return value from sqlite3 function Coverity: 108596 Signed-off-by: surya.kumar7 Change-Id: I94b669d856bc0213274fc1d86857fd395bb846d6 --- common/app_db.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/common/app_db.cc b/common/app_db.cc index fa6a3c6..386b8da 100644 --- a/common/app_db.cc +++ b/common/app_db.cc @@ -218,7 +218,7 @@ void SqliteDB::Initialize() { sqldb_ = NULL; return; } - sqlite3_busy_handler(sqldb_, [](void *, int count) { + ret = sqlite3_busy_handler(sqldb_, [](void *, int count) { if (count < 5) { LOGGER(ERROR) << "App db was busy, Wait the lock count(" << count << ")"; usleep(100000*(count+1)); @@ -228,6 +228,9 @@ void SqliteDB::Initialize() { return 0; } }, NULL); + if (ret != SQLITE_OK) { + LOGGER(ERROR) << "Failed to register busy handler: " << sqlite3_errmsg(sqldb_); + } char *errmsg = NULL; ret = sqlite3_exec(sqldb_, kCreateDbQuery, NULL, NULL, &errmsg); -- 2.7.4 From 4654ffaebfa0be3a78c6d3177991ea7385d7dc31 Mon Sep 17 00:00:00 2001 From: "surya.kumar7" Date: Fri, 6 Apr 2018 20:25:47 +0530 Subject: [PATCH 09/16] Coverity error handling Terminate string tainted by fread Coverity: 110097 Change-Id: Icfd7798e775a4bd4db383173ce5bbaf033cf7d6c Signed-off-by: surya.kumar7 --- common/resource_manager.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/common/resource_manager.cc b/common/resource_manager.cc index 8881428..42327b9 100755 --- a/common/resource_manager.cc +++ b/common/resource_manager.cc @@ -645,6 +645,7 @@ std::string ResourceManager::DecryptResource(const std::string& path) { size_t read_size = fread(get_dec_size, 1, 4, src); + get_dec_size[read_size] = '\0'; if (0 != read_size) { unsigned int read_buf_size = 0; std::istringstream(std::string((char*)get_dec_size)) >> read_buf_size; -- 2.7.4 From 10e9a1af00023cd085d3c8794d9c8165ec53a9ba Mon Sep 17 00:00:00 2001 From: "surya.kumar7" Date: Fri, 6 Apr 2018 20:05:20 +0530 Subject: [PATCH 10/16] Coverity error handling Preload function is of type std::function and should not return a bool value Coverity: 108784 Change-Id: Ia4f7c601cf1692c347eab2d83f6936b497e14f70 Signed-off-by: surya.kumar7 --- runtime/browser/runtime_process.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/browser/runtime_process.cc b/runtime/browser/runtime_process.cc index e397c27..bd6b22b 100755 --- a/runtime/browser/runtime_process.cc +++ b/runtime/browser/runtime_process.cc @@ -154,7 +154,7 @@ int main(int argc, char* argv[]) { LOGGER(DEBUG) << "run with wrt-loader"; if (!ewk_init()) { LOGGER(ERROR) << "could not init ewk"; - return false; + return; } g_prelaunch = true; char* chromium_arg_options[] = { -- 2.7.4 From 49435ec874471be8e6888226e3a6305252895ae3 Mon Sep 17 00:00:00 2001 From: Youngsoo Choi Date: Mon, 16 Apr 2018 06:14:37 +0000 Subject: [PATCH 11/16] [M63] Remove the limit of chromium-efl version To be built with m63 chromium-efl, this removes the limit of chromium-efl version. Change-Id: Icd40b6f5eb2661539b9c67598ca59d736937ddd8 Signed-off-by: Youngsoo Choi --- packaging/crosswalk-tizen.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packaging/crosswalk-tizen.spec b/packaging/crosswalk-tizen.spec index 0c24483..ef737f3 100755 --- a/packaging/crosswalk-tizen.spec +++ b/packaging/crosswalk-tizen.spec @@ -29,7 +29,7 @@ BuildRequires: pkgconfig(capi-appfw-package-manager) BuildRequires: pkgconfig(capi-system-system-settings) BuildRequires: pkgconfig(capi-system-info) BuildRequires: pkgconfig(capi-ui-efl-util) -BuildRequires: pkgconfig(chromium-efl) >= 56.0.0, pkgconfig(chromium-efl) < 57.0.0 +BuildRequires: pkgconfig(chromium-efl) >= 56.0.0 BuildRequires: pkgconfig(cynara-client) BuildRequires: pkgconfig(capi-system-device) BuildRequires: pkgconfig(dlog) -- 2.7.4 From b18a93c2ef8efec5b6a62730279c747632c49521 Mon Sep 17 00:00:00 2001 From: Youngsoo Choi Date: Mon, 2 Apr 2018 01:52:13 -0700 Subject: [PATCH 12/16] [M63] Switch deprecated ForceSet with DefineOwnProperty ForceSet has been deprecated in v8 version 6.3.292. So, this switches the ForceSet with DefineOwnProperty. Change-Id: Ied9dcf71ec447b9a1dcd15c4b6ab6ed8420a20d6 Signed-off-by: Youngsoo Choi --- extensions/renderer/xwalk_module_system.cc | 2 +- extensions/renderer/xwalk_v8tools_module.cc | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/extensions/renderer/xwalk_module_system.cc b/extensions/renderer/xwalk_module_system.cc index 2218188..e2d1a9a 100755 --- a/extensions/renderer/xwalk_module_system.cc +++ b/extensions/renderer/xwalk_module_system.cc @@ -516,7 +516,7 @@ void XWalkModuleSystem::EnsureExtensionNamespaceIsReadOnly( v8::Handle v8_extension_name( v8::String::NewFromUtf8(context->GetIsolate(), basename.c_str())); - value.As()->ForceSet( + value.As()->DefineOwnProperty(context, v8_extension_name, value.As()->Get(v8_extension_name), v8::ReadOnly); } diff --git a/extensions/renderer/xwalk_v8tools_module.cc b/extensions/renderer/xwalk_v8tools_module.cc index 4fcad37..941851d 100755 --- a/extensions/renderer/xwalk_v8tools_module.cc +++ b/extensions/renderer/xwalk_v8tools_module.cc @@ -18,7 +18,11 @@ void ForceSetPropertyCallback( if (info.Length() != 3 || !info[0]->IsObject() || !info[1]->IsString()) { return; } - info[0].As()->ForceSet(info[1], info[2]); + v8::Isolate* isolate = v8::Isolate::GetCurrent(); + v8::Local ctx = isolate->GetCurrentContext(); + v8::String::Utf8Value value(info[1]); + v8::Local key = v8::String::NewFromUtf8(isolate, *value); + info[0].As()->DefineOwnProperty(ctx, key, info[2]); } // ================ -- 2.7.4 From 297d926a8987b59c8a29ae1a48c1b83d38d069f9 Mon Sep 17 00:00:00 2001 From: Guneet K Date: Mon, 14 May 2018 12:25:41 +0530 Subject: [PATCH 13/16] coverity error handling This patch initializes uninitialized member variable. Coverity:107447,110284 Change-Id: I86cd7feafa845323c502ababf1f9287d93818eac Signed-off-by: Guneet K --- common/app_control.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/common/app_control.cc b/common/app_control.cc index 8fbe4e8..aa14230 100755 --- a/common/app_control.cc +++ b/common/app_control.cc @@ -108,13 +108,15 @@ static void AppendExtraDatafromUrl(AppControl* request, } // namespace AppControl::AppControl(app_control_h app_control) - : app_control_bundle_(nullptr){ + : app_control_bundle_(nullptr), + app_control_(NULL){ app_control_clone(&app_control_, app_control); app_control_to_bundle(app_control_, &app_control_bundle_); } AppControl:: AppControl() - : app_control_bundle_(nullptr){ + : app_control_bundle_(nullptr), + app_control_(NULL){ app_control_create(&app_control_); app_control_to_bundle(app_control_, &app_control_bundle_); } -- 2.7.4 From a36aa4468025350d6563b950aafaec69096626e1 Mon Sep 17 00:00:00 2001 From: Guneet K Date: Mon, 14 May 2018 15:12:22 +0530 Subject: [PATCH 14/16] coverity error handling This patch makes handle_ a data member of XWalkExtension class. dlclose(handle_) is called from XWalkExtension class destructor to prevent resource leak. Coverity:109521 Change-Id: I24ae7763809536b3b5ad486c7f45c7c40a9dc528 Signed-off-by: Guneet K --- extensions/common/xwalk_extension.cc | 13 ++++++++----- extensions/common/xwalk_extension.h | 1 + 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/extensions/common/xwalk_extension.cc b/extensions/common/xwalk_extension.cc index a5f9292..f1ecfa5 100755 --- a/extensions/common/xwalk_extension.cc +++ b/extensions/common/xwalk_extension.cc @@ -20,6 +20,7 @@ XWalkExtension::XWalkExtension(const std::string& path, library_path_(path), xw_extension_(0), lazy_loading_(false), + handle_(nullptr), delegate_(delegate), created_instance_callback_(NULL), destroyed_instance_callback_(NULL), @@ -39,6 +40,7 @@ XWalkExtension::XWalkExtension(const std::string& path, name_(name), entry_points_(entry_points), lazy_loading_(true), + handle_(nullptr), delegate_(delegate), created_instance_callback_(NULL), destroyed_instance_callback_(NULL), @@ -54,25 +56,26 @@ XWalkExtension::~XWalkExtension() { if (shutdown_callback_) shutdown_callback_(xw_extension_); XWalkExtensionAdapter::GetInstance()->UnregisterExtension(this); + dlclose(handle_); } bool XWalkExtension::Initialize() { if (initialized_) return true; - void* handle = dlopen(library_path_.c_str(), RTLD_LAZY); - if (!handle) { + handle_ = dlopen(library_path_.c_str(), RTLD_LAZY); + if (!handle_) { LOGGER(ERROR) << "Error loading extension '" << library_path_ << "' : " << dlerror(); return false; } XW_Initialize_Func initialize = reinterpret_cast( - dlsym(handle, "XW_Initialize")); + dlsym(handle_, "XW_Initialize")); if (!initialize) { LOGGER(ERROR) << "Error loading extension '" << library_path_ << "' : couldn't get XW_Initialize function."; - dlclose(handle); + dlclose(handle_); return false; } @@ -84,7 +87,7 @@ bool XWalkExtension::Initialize() { if (ret != XW_OK) { LOGGER(ERROR) << "Error loading extension '" << library_path_ << "' : XW_Initialize() returned error value."; - dlclose(handle); + dlclose(handle_); return false; } diff --git a/extensions/common/xwalk_extension.h b/extensions/common/xwalk_extension.h index c7aaf83..6b19630 100755 --- a/extensions/common/xwalk_extension.h +++ b/extensions/common/xwalk_extension.h @@ -66,6 +66,7 @@ class XWalkExtension { std::string javascript_api_; StringVector entry_points_; bool lazy_loading_; + void *handle_; XWalkExtensionDelegate* delegate_; -- 2.7.4 From c8c1a1c5d78776c99fff97a1c86ab041bb5a29ec Mon Sep 17 00:00:00 2001 From: Guneet K Date: Mon, 14 May 2018 16:08:34 +0530 Subject: [PATCH 15/16] coverity error handling This patch makes handle_ a data member of XWalkExtensionManager class. dlclose(handle_) is called from XWalkExtensionManager class destructor to prevent resource leak. coverity:109521 Change-Id: I4751e38e50b491dc54a893d5c9d1da4e41ab90f0 Signed-off-by: Guneet K --- extensions/common/xwalk_extension_manager.cc | 9 ++++++--- extensions/common/xwalk_extension_manager.h | 1 + 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/extensions/common/xwalk_extension_manager.cc b/extensions/common/xwalk_extension_manager.cc index 130eca8..f0e3084 100755 --- a/extensions/common/xwalk_extension_manager.cc +++ b/extensions/common/xwalk_extension_manager.cc @@ -55,15 +55,18 @@ XWalkExtensionManager::XWalkExtensionManager() { } XWalkExtensionManager::~XWalkExtensionManager() { + for (auto dlhandle : handle_) + dlclose(dlhandle); } void XWalkExtensionManager::PreloadExtensions() { for (int i = 0; kPreloadLibs[i]; i++) { LOGGER(DEBUG) << "Preload libs : " << kPreloadLibs[i]; - void* handle = dlopen(kPreloadLibs[i], RTLD_NOW|RTLD_GLOBAL); - if (handle == nullptr) { + void *dlhandle = dlopen(kPreloadLibs[i], RTLD_NOW|RTLD_GLOBAL); + if (dlhandle == nullptr) LOGGER(WARN) << "Fail to load libs : " << dlerror(); - } + else + handle_.push_back(dlhandle); } } diff --git a/extensions/common/xwalk_extension_manager.h b/extensions/common/xwalk_extension_manager.h index cfbdede..786edfc 100755 --- a/extensions/common/xwalk_extension_manager.h +++ b/extensions/common/xwalk_extension_manager.h @@ -40,6 +40,7 @@ class XWalkExtensionManager : public XWalkExtension::XWalkExtensionDelegate { StringSet extension_symbols_; ExtensionMap extensions_; + std::vector handle_; }; } // namespace extensions -- 2.7.4 From d9b1c47c315d6c8f74b5ce60683ddc923987a59a Mon Sep 17 00:00:00 2001 From: Guneet K Date: Wed, 16 May 2018 18:06:30 +0530 Subject: [PATCH 16/16] Hotfix for "App Not Launch" Issue This patch removes the initialization of window using wrt-loader. The initialization of window happens at actual launch time. Change-Id: I6e1c16defbf5cf9283184cdc5cf056136e8a555f Signed-off-by: Guneet K --- runtime/browser/preload_manager.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/browser/preload_manager.cc b/runtime/browser/preload_manager.cc index 53317ae..fe1cce7 100755 --- a/runtime/browser/preload_manager.cc +++ b/runtime/browser/preload_manager.cc @@ -49,7 +49,7 @@ void PreloadManager::CreateCacheComponet() { ewk_context_new_with_injected_bundle_path(INJECTED_BUNDLE_PATH); context = context; // To prevent build warning cached_window_.reset(new NativeAppWindow()); - cached_window_->Initialize(); + //cached_window_->Initialize(); } NativeWindow* PreloadManager::GetCachedNativeWindow() { -- 2.7.4