diff options
-rw-r--r-- | base/allocator/allocator_shim.cc | 4 | ||||
-rw-r--r-- | base/file_util_win.cc | 3 | ||||
-rw-r--r-- | base/process_util_win.cc | 2 | ||||
-rw-r--r-- | base/win/sampling_profiler.cc | 4 | ||||
-rw-r--r-- | chrome/installer/util/shell_util.cc | 18 |
5 files changed, 16 insertions, 15 deletions
diff --git a/base/allocator/allocator_shim.cc b/base/allocator/allocator_shim.cc index 97bbf90..097fff2 100644 --- a/base/allocator/allocator_shim.cc +++ b/base/allocator/allocator_shim.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -294,7 +294,7 @@ void SetupSubprocessAllocator() { buffer[sizeof(buffer) - 1] = '\0'; if (secondary_length || !primary_length) { - char* secondary_value = secondary_length ? buffer : "TCMALLOC"; + const char* secondary_value = secondary_length ? buffer : "TCMALLOC"; // Force renderer (or other subprocesses) to use secondary_value. int ret_val = _putenv_s(primary_name, secondary_value); DCHECK_EQ(0, ret_val); diff --git a/base/file_util_win.cc b/base/file_util_win.cc index d1337a2..eb72afb 100644 --- a/base/file_util_win.cc +++ b/base/file_util_win.cc @@ -988,8 +988,9 @@ void MemoryMappedFile::CloseHandles() { bool HasFileBeenModifiedSince(const FileEnumerator::FindInfo& find_info, const base::Time& cutoff_time) { base::ThreadRestrictions::AssertIOAllowed(); + FILETIME file_time = cutoff_time.ToFileTime(); long result = CompareFileTime(&find_info.ftLastWriteTime, // NOLINT - &cutoff_time.ToFileTime()); + &file_time); return result == 1 || result == 0; } diff --git a/base/process_util_win.cc b/base/process_util_win.cc index 19041cc..ae5ee6a 100644 --- a/base/process_util_win.cc +++ b/base/process_util_win.cc @@ -592,7 +592,7 @@ bool WaitForProcessesToExit(const std::wstring& executable_name, DWORD start_time = GetTickCount(); NamedProcessIterator iter(executable_name, filter); - while (entry = iter.NextProcessEntry()) { + while ((entry = iter.NextProcessEntry())) { DWORD remaining_wait = std::max<int64>(0, wait_milliseconds - (GetTickCount() - start_time)); HANDLE process = OpenProcess(SYNCHRONIZE, diff --git a/base/win/sampling_profiler.cc b/base/win/sampling_profiler.cc index 400eb63..dd510ac 100644 --- a/base/win/sampling_profiler.cc +++ b/base/win/sampling_profiler.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -104,7 +104,7 @@ ProfilerFuncs::ProfilerFuncs() } } -base::LazyInstance<ProfilerFuncs, base::LeakyLazyInstanceTraits<ProfilerFuncs>> +base::LazyInstance<ProfilerFuncs, base::LeakyLazyInstanceTraits<ProfilerFuncs> > funcs = LAZY_INSTANCE_INITIALIZER; } // namespace diff --git a/chrome/installer/util/shell_util.cc b/chrome/installer/util/shell_util.cc index 3e453f64..68f409e 100644 --- a/chrome/installer/util/shell_util.cc +++ b/chrome/installer/util/shell_util.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // @@ -358,7 +358,7 @@ bool IsChromeRegistered(BrowserDistribution* dist, const std::wstring& suffix) { bool registered = true; std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProgIdEntries(dist, chrome_exe, suffix, &entries); RegistryEntry::GetSystemEntries(dist, chrome_exe, suffix, &entries); for (std::list<RegistryEntry*>::const_iterator itr = entries.begin(); @@ -377,7 +377,7 @@ bool IsChromeRegisteredForProtocol(BrowserDistribution* dist, const std::wstring& protocol) { bool registered = true; std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProtocolCapabilityEntries(dist, suffix, protocol, &entries); for (std::list<RegistryEntry*>::const_iterator itr = entries.begin(); itr != entries.end() && registered; ++itr) { @@ -532,7 +532,7 @@ bool ShellUtil::AdminNeededForRegistryCleanup(BrowserDistribution* dist, const std::wstring& suffix) { bool cleanup_needed = false; std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProgIdEntries(dist, L"chrome.exe", suffix, &entries); RegistryEntry::GetSystemEntries(dist, L"chrome.exe", suffix, &entries); for (std::list<RegistryEntry*>::const_iterator itr = entries.begin(); @@ -803,7 +803,7 @@ bool ShellUtil::MakeChromeDefault(BrowserDistribution* dist, // this on Vista also. std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); std::wstring suffix; if (!GetUserSpecificDefaultBrowserSuffix(dist, &suffix)) suffix = L""; @@ -866,7 +866,7 @@ bool ShellUtil::MakeChromeDefaultProtocolClient(BrowserDistribution* dist, // Software\Classes\http key directly, we have to do this on Vista also. std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); std::wstring suffix; if (!GetUserSpecificDefaultBrowserSuffix(dist, &suffix)) suffix = L""; @@ -908,7 +908,7 @@ bool ShellUtil::RegisterChromeBrowser(BrowserDistribution* dist, // If user is an admin try to register and return the status. if (IsUserAnAdmin()) { std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProgIdEntries(dist, chrome_exe, suffix, &entries); RegistryEntry::GetSystemEntries(dist, chrome_exe, suffix, &entries); return AddRegistryEntries(HKEY_LOCAL_MACHINE, entries); @@ -923,7 +923,7 @@ bool ShellUtil::RegisterChromeBrowser(BrowserDistribution* dist, // If we got to this point then all we can do is create ProgIds under HKCU // on XP as well as Vista. std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProgIdEntries(dist, chrome_exe, L"", &entries); return AddRegistryEntries(HKEY_CURRENT_USER, entries); } @@ -962,7 +962,7 @@ bool ShellUtil::RegisterChromeForProtocol(BrowserDistribution* dist, // Write in the capabillity for the protocol. std::list<RegistryEntry*> entries; - STLElementDeleter<std::list<RegistryEntry*>> entries_deleter(&entries); + STLElementDeleter<std::list<RegistryEntry*> > entries_deleter(&entries); RegistryEntry::GetProtocolCapabilityEntries(dist, suffix, protocol, &entries); return AddRegistryEntries(HKEY_LOCAL_MACHINE, entries); |