diff options
author | kuchhal@chromium.org <kuchhal@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-05 00:01:04 +0000 |
---|---|---|
committer | kuchhal@chromium.org <kuchhal@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-05 00:01:04 +0000 |
commit | 0e097dbc1b1638d95c6f5b13482472e7233a5a1c (patch) | |
tree | 387af1708c8c10d1bc881067b2a1ac26af7b68fe /chrome | |
parent | 48d4387babfc1e9a78028bce546bdccddb2e542b (diff) | |
download | chromium_src-0e097dbc1b1638d95c6f5b13482472e7233a5a1c.zip chromium_src-0e097dbc1b1638d95c6f5b13482472e7233a5a1c.tar.gz chromium_src-0e097dbc1b1638d95c6f5b13482472e7233a5a1c.tar.bz2 |
Always write 'dr' key to HKCU.
Review URL: http://codereview.chromium.org/9291
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4710 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rwxr-xr-x[-rw-r--r--] | chrome/app/google_update_client.cc | 5 | ||||
-rw-r--r-- | chrome/app/google_update_client.h | 2 |
2 files changed, 1 insertions, 6 deletions
diff --git a/chrome/app/google_update_client.cc b/chrome/app/google_update_client.cc index 8ae8aee..046c560f 100644..100755 --- a/chrome/app/google_update_client.cc +++ b/chrome/app/google_update_client.cc @@ -81,10 +81,9 @@ bool GoogleUpdateClient::Launch(HINSTANCE instance, ::GetProcAddress(dll_handle, entry_name)); if (NULL != entry) { // record did_run "dr" in client state - HKEY reg_root = (user_mode_) ? HKEY_CURRENT_USER : HKEY_LOCAL_MACHINE; std::wstring key_path = google_update::kRegPathClientState + guid_; HKEY reg_key; - if (::RegOpenKeyEx(reg_root, key_path.c_str(), 0, + if (::RegOpenKeyEx(HKEY_CURRENT_USER, key_path.c_str(), 0, KEY_WRITE, ®_key) == ERROR_SUCCESS) { const wchar_t kVal[] = L"1"; ::RegSetValueEx(reg_key, google_update::kRegDidRunField, 0, REG_SZ, @@ -109,8 +108,6 @@ bool GoogleUpdateClient::Launch(HINSTANCE instance, bool GoogleUpdateClient::Init(const wchar_t* client_guid, const wchar_t* client_dll) { client_util::GetExecutablePath(dll_path_); - user_mode_ = InstallUtil::IsPerUserInstall(dll_path_); - guid_.assign(client_guid); dll_.assign(client_dll); bool ret = false; diff --git a/chrome/app/google_update_client.h b/chrome/app/google_update_client.h index 479a360..664c4e5 100644 --- a/chrome/app/google_update_client.h +++ b/chrome/app/google_update_client.h @@ -72,8 +72,6 @@ class GoogleUpdateClient { wchar_t* version_; // The location of current chrome.dll. wchar_t dll_path_[MAX_PATH]; - // Are we running in user mode or admin mode - bool user_mode_; }; } // namespace google_update |