alloy: Remove CefSettings.user_data_path (fixes #3511)

This change replaces existing CefSettings.user_data_path usage with
CefSettings.root_cache_path for better alignment with the Chrome runtime.
All files should now be written inside the root_cache_path directory.
This commit is contained in:
Marshall Greenblatt
2023-06-06 17:41:53 +03:00
parent 36a645ffd8
commit b5386249bd
11 changed files with 37 additions and 62 deletions

View File

@@ -33,7 +33,7 @@
// by hand. See the translator.README.txt file in the tools directory for
// more information.
//
// $hash=5c6e0b9e37b8103a182f200fccdf5973104fcd70$
// $hash=22cfd717df9032a01214d9abfe3e0e51949b3319$
//
#ifndef CEF_INCLUDE_CAPI_CEF_CRASH_UTIL_CAPI_H_
@@ -90,7 +90,7 @@ extern "C" {
/// If "AppName" is set on Windows then crash report information (metrics,
/// database and dumps) will be stored locally on disk under the
/// "C:\Users\[CurrentUser]\AppData\Local\[AppName]\User Data" folder. On other
/// platforms the cef_settings_t.user_data_path value will be used.
/// platforms the cef_settings_t.root_cache_path value will be used.
///
/// If "ExternalHandler" is set on Windows then the specified exe will be
/// launched as the crashpad-handler instead of re-launching the main process

View File

@@ -42,13 +42,13 @@
// way that may cause binary incompatibility with other builds. The universal
// hash value will change if any platform is affected whereas the platform hash
// values will change only if that particular platform is affected.
#define CEF_API_HASH_UNIVERSAL "19ae20c25645845eb850e794d6a5720e62ca0da2"
#define CEF_API_HASH_UNIVERSAL "5ee382b5a4b7a02d0285f9af00e9205e03b456d0"
#if defined(OS_WIN)
#define CEF_API_HASH_PLATFORM "c9755cb731be425f3e92c7be23908ca3c8ac26b4"
#define CEF_API_HASH_PLATFORM "f4db8c7c65b7a95af22e0adf0c6b86c087d988f1"
#elif defined(OS_MAC)
#define CEF_API_HASH_PLATFORM "794acfa185a6be3edea15de4a8bbafebccc7e34c"
#define CEF_API_HASH_PLATFORM "932566b79377996c56a3d97128404491f94699cf"
#elif defined(OS_LINUX)
#define CEF_API_HASH_PLATFORM "39de0cd2c1d9b526c77deb72a77bbeaa5254c309"
#define CEF_API_HASH_PLATFORM "ae753fb624eec885a3dc64c815360f9bca58f17e"
#endif
#ifdef __cplusplus

View File

@@ -82,7 +82,7 @@
/// If "AppName" is set on Windows then crash report information (metrics,
/// database and dumps) will be stored locally on disk under the
/// "C:\Users\[CurrentUser]\AppData\Local\[AppName]\User Data" folder. On other
/// platforms the cef_settings_t.user_data_path value will be used.
/// platforms the cef_settings_t.root_cache_path value will be used.
///
/// If "ExternalHandler" is set on Windows then the specified exe will be
/// launched as the crashpad-handler instead of re-launching the main process

View File

@@ -260,24 +260,16 @@ typedef struct _cef_settings_t {
/// The root directory that all CefSettings.cache_path and
/// CefRequestContextSettings.cache_path values must have in common. If this
/// value is empty and CefSettings.cache_path is non-empty then it will
/// default to the CefSettings.cache_path value. If this value is non-empty
/// then it must be an absolute path. Failure to set this value correctly may
/// result in the sandbox blocking read/write access to the cache_path
/// directory.
///
cef_string_t root_cache_path;
///
/// The location where user data such as the Widevine CDM module and spell
/// checking dictionary files will be stored on disk. If this value is empty
/// then the default platform-specific user data directory will be used
/// default to the CefSettings.cache_path value. If both values are empty
/// then the default platform-specific directory will be used
/// ("~/.config/cef_user_data" directory on Linux, "~/Library/Application
/// Support/CEF/User Data" directory on MacOS, "AppData\Local\CEF\User Data"
/// directory under the user profile directory on Windows). If this value is
/// non-empty then it must be an absolute path. When using the Chrome runtime
/// this value will be ignored in favor of the |root_cache_path| value.
/// non-empty then it must be an absolute path. Failure to set this value
/// correctly may result in the sandbox blocking read/write access to certain
/// files.
///
cef_string_t user_data_path;
cef_string_t root_cache_path;
///
/// To persist session cookies (cookies without an expiry date or validity

View File

@@ -364,7 +364,6 @@ struct CefSettingsTraits {
cef_string_clear(&s->main_bundle_path);
cef_string_clear(&s->cache_path);
cef_string_clear(&s->root_cache_path);
cef_string_clear(&s->user_data_path);
cef_string_clear(&s->user_agent);
cef_string_clear(&s->user_agent_product);
cef_string_clear(&s->locale);
@@ -397,8 +396,6 @@ struct CefSettingsTraits {
&target->cache_path, copy);
cef_string_set(src->root_cache_path.str, src->root_cache_path.length,
&target->root_cache_path, copy);
cef_string_set(src->user_data_path.str, src->user_data_path.length,
&target->user_data_path, copy);
target->persist_session_cookies = src->persist_session_cookies;
target->persist_user_preferences = src->persist_user_preferences;