Skip to content

Commit

Permalink
Fix path override ordering (fixes #3749)
Browse files Browse the repository at this point in the history
The chrome::DIR_RESOURCES and ui::DIR_LOCALES overrides need to be
configured before calling ChromeMainDelegate::PreSandboxStartup.
  • Loading branch information
magreenblatt committed Aug 8, 2024
1 parent ebb3c96 commit 889cfcf
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions libcef/common/chrome/chrome_main_delegate_cef.cc
Original file line number Diff line number Diff line change
Expand Up @@ -377,12 +377,6 @@ void ChromeMainDelegateCef::PreSandboxStartup() {
// number in the app bundle path.
resource_util::OverrideUserDataDir(settings_, command_line);

ChromeMainDelegate::PreSandboxStartup();

// Initialize crash reporting state for this process/module.
// chrome::DIR_CRASH_DUMPS must be configured before calling this function.
crash_reporting::PreSandboxStartup(*command_line, process_type);

base::FilePath resources_dir;
if (command_line->HasSwitch(switches::kResourcesDirPath)) {
resources_dir =
Expand All @@ -403,6 +397,12 @@ void ChromeMainDelegateCef::PreSandboxStartup() {
}
}

ChromeMainDelegate::PreSandboxStartup();

// Initialize crash reporting state for this process/module.
// chrome::DIR_CRASH_DUMPS must be configured before calling this function.
crash_reporting::PreSandboxStartup(*command_line, process_type);

#if !BUILDFLAG(IS_WIN)
// Call after InitLogging() potentially changes values in
// chrome/app/chrome_main_delegate.cc.
Expand Down

0 comments on commit 889cfcf

Please sign in to comment.