Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(787)

Side by Side Diff: chrome/installer/setup/install_worker.cc

Issue 1764053002: Revert of Delete old files after an update. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | chrome/installer/setup/setup_main.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // This file contains the definitions of the installer functions that build 5 // This file contains the definitions of the installer functions that build
6 // the WorkItemList used to install the application. 6 // the WorkItemList used to install the application.
7 7
8 #include "chrome/installer/setup/install_worker.h" 8 #include "chrome/installer/setup/install_worker.h"
9 9
10 #include <oaidl.h> 10 #include <oaidl.h>
(...skipping 22 matching lines...) Expand all
33 #include "chrome/installer/setup/app_launcher_installer.h" 33 #include "chrome/installer/setup/app_launcher_installer.h"
34 #include "chrome/installer/setup/install.h" 34 #include "chrome/installer/setup/install.h"
35 #include "chrome/installer/setup/setup_constants.h" 35 #include "chrome/installer/setup/setup_constants.h"
36 #include "chrome/installer/setup/setup_util.h" 36 #include "chrome/installer/setup/setup_util.h"
37 #include "chrome/installer/setup/update_active_setup_version_work_item.h" 37 #include "chrome/installer/setup/update_active_setup_version_work_item.h"
38 #include "chrome/installer/util/app_registration_data.h" 38 #include "chrome/installer/util/app_registration_data.h"
39 #include "chrome/installer/util/browser_distribution.h" 39 #include "chrome/installer/util/browser_distribution.h"
40 #include "chrome/installer/util/callback_work_item.h" 40 #include "chrome/installer/util/callback_work_item.h"
41 #include "chrome/installer/util/conditional_work_item_list.h" 41 #include "chrome/installer/util/conditional_work_item_list.h"
42 #include "chrome/installer/util/create_reg_key_work_item.h" 42 #include "chrome/installer/util/create_reg_key_work_item.h"
43 #include "chrome/installer/util/delete_old_versions.h"
44 #include "chrome/installer/util/firewall_manager_win.h" 43 #include "chrome/installer/util/firewall_manager_win.h"
45 #include "chrome/installer/util/google_update_constants.h" 44 #include "chrome/installer/util/google_update_constants.h"
46 #include "chrome/installer/util/helper.h" 45 #include "chrome/installer/util/helper.h"
47 #include "chrome/installer/util/install_util.h" 46 #include "chrome/installer/util/install_util.h"
48 #include "chrome/installer/util/installation_state.h" 47 #include "chrome/installer/util/installation_state.h"
49 #include "chrome/installer/util/installer_state.h" 48 #include "chrome/installer/util/installer_state.h"
50 #include "chrome/installer/util/l10n_string_util.h" 49 #include "chrome/installer/util/l10n_string_util.h"
51 #include "chrome/installer/util/product.h" 50 #include "chrome/installer/util/product.h"
52 #include "chrome/installer/util/set_reg_value_work_item.h" 51 #include "chrome/installer/util/set_reg_value_work_item.h"
53 #include "chrome/installer/util/shell_util.h" 52 #include "chrome/installer/util/shell_util.h"
(...skipping 948 matching lines...) Expand 10 before | Expand all | Expand 10 after
1002 regular_update_work_items->AddDeleteRegValueWorkItem( 1001 regular_update_work_items->AddDeleteRegValueWorkItem(
1003 root, 1002 root,
1004 version_key, 1003 version_key,
1005 KEY_WOW64_32KEY, 1004 KEY_WOW64_32KEY,
1006 google_update::kRegRenameCmdField); 1005 google_update::kRegRenameCmdField);
1007 } 1006 }
1008 1007
1009 post_install_task_list->AddWorkItem(regular_update_work_items.release()); 1008 post_install_task_list->AddWorkItem(regular_update_work_items.release());
1010 } 1009 }
1011 1010
1012 // If this is a regular update (chrome.exe not in use), this step will try to
1013 // delete files from all versions except the one that was just installed.
1014 // Otherwise, it will try to delete files from all versions except the one
1015 // that is in use and the one that was just installed.
1016 AddDeleteOldVersionsWorkItem(installer_state, post_install_task_list);
1017
1018 AddRegisterComDllWorkItemsForPackage(installer_state, current_version, 1011 AddRegisterComDllWorkItemsForPackage(installer_state, current_version,
1019 new_version, post_install_task_list); 1012 new_version, post_install_task_list);
1020 1013
1021 // If we're told that we're an MSI install, make sure to set the marker 1014 // If we're told that we're an MSI install, make sure to set the marker
1022 // in the client state key so that future updates do the right thing. 1015 // in the client state key so that future updates do the right thing.
1023 if (installer_state.is_msi()) { 1016 if (installer_state.is_msi()) {
1024 for (size_t i = 0; i < products.size(); ++i) { 1017 for (size_t i = 0; i < products.size(); ++i) {
1025 const Product* product = products[i]; 1018 const Product* product = products[i];
1026 AddSetMsiMarkerWorkItem(installer_state, product->distribution(), true, 1019 AddSetMsiMarkerWorkItem(installer_state, product->distribution(), true,
1027 post_install_task_list); 1020 post_install_task_list);
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
1361 // Unconditionally remove the legacy Quick Enable command from the binaries. 1354 // Unconditionally remove the legacy Quick Enable command from the binaries.
1362 // Do this even if multi-install Chrome isn't installed to ensure that it is 1355 // Do this even if multi-install Chrome isn't installed to ensure that it is
1363 // not left behind in any case. 1356 // not left behind in any case.
1364 work_item_list->AddDeleteRegKeyWorkItem( 1357 work_item_list->AddDeleteRegKeyWorkItem(
1365 installer_state.root_key(), cmd_key, KEY_WOW64_32KEY) 1358 installer_state.root_key(), cmd_key, KEY_WOW64_32KEY)
1366 ->set_log_message("removing " + base::UTF16ToASCII(kCmdQuickEnableCf) + 1359 ->set_log_message("removing " + base::UTF16ToASCII(kCmdQuickEnableCf) +
1367 " command"); 1360 " command");
1368 } 1361 }
1369 1362
1370 } // namespace installer 1363 } // namespace installer
OLDNEW
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | chrome/installer/setup/setup_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698