summaryrefslogtreecommitdiffstats
path: root/chrome_frame
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-14 02:13:43 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-14 02:13:43 +0000
commit87e70062789c3695762c0ddaca1a759e8834398a (patch)
tree613a0a5fb74bc0ca8417976788fcce2666753d23 /chrome_frame
parentb5ff342a5aca83396114933152ad5d644f536375 (diff)
downloadchromium_src-87e70062789c3695762c0ddaca1a759e8834398a.zip
chromium_src-87e70062789c3695762c0ddaca1a759e8834398a.tar.gz
chromium_src-87e70062789c3695762c0ddaca1a759e8834398a.tar.bz2
Cleanup Registry API: part 3.
- Remove the default arguments from the constructor. - Add a empty constructor to handle the case of the default arguments were used. BUG=44644 TEST=trybots Review URL: http://codereview.chromium.org/3172009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56123 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame')
-rw-r--r--chrome_frame/test/chrome_frame_test_utils.cc4
-rw-r--r--chrome_frame/test/perf/chrome_frame_perftest.cc4
2 files changed, 4 insertions, 4 deletions
diff --git a/chrome_frame/test/chrome_frame_test_utils.cc b/chrome_frame/test/chrome_frame_test_utils.cc
index f5b1315..9c43cb2 100644
--- a/chrome_frame/test/chrome_frame_test_utils.cc
+++ b/chrome_frame/test/chrome_frame_test_utils.cc
@@ -118,7 +118,7 @@ std::wstring GetExecutableAppPath(const std::wstring& file) {
L"SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\";
std::wstring app_path;
- RegKey key(HKEY_LOCAL_MACHINE, (kAppPathsKey + file).c_str());
+ RegKey key(HKEY_LOCAL_MACHINE, (kAppPathsKey + file).c_str(), KEY_READ);
if (key.Handle()) {
key.ReadValue(NULL, &app_path);
}
@@ -130,7 +130,7 @@ std::wstring FormatCommandForApp(const std::wstring& exe_name,
const std::wstring& argument) {
std::wstring reg_path(StringPrintf(L"Applications\\%ls\\shell\\open\\command",
exe_name.c_str()));
- RegKey key(HKEY_CLASSES_ROOT, reg_path.c_str());
+ RegKey key(HKEY_CLASSES_ROOT, reg_path.c_str(), KEY_READ);
std::wstring command;
if (key.Handle()) {
diff --git a/chrome_frame/test/perf/chrome_frame_perftest.cc b/chrome_frame/test/perf/chrome_frame_perftest.cc
index d53d407..d283b0c 100644
--- a/chrome_frame/test/perf/chrome_frame_perftest.cc
+++ b/chrome_frame/test/perf/chrome_frame_perftest.cc
@@ -1091,7 +1091,7 @@ TEST_F(ChromeFrameCreationTest, PerfCold) {
// from the cache. This could also fail if the Flash control is in use.
// On Vista this could fail because of UAC
TEST_F(FlashCreationTest, PerfCold) {
- RegKey flash_key(HKEY_CLASSES_ROOT, kFlashControlKey);
+ RegKey flash_key(HKEY_CLASSES_ROOT, kFlashControlKey, KEY_READ);
std::wstring plugin_path;
ASSERT_TRUE(flash_key.ReadValue(L"", &plugin_path));
@@ -1111,7 +1111,7 @@ TEST_F(FlashCreationTest, PerfCold) {
// correctly causing the attempt to evict the dll from the system cache to
// fail.
TEST_F(SilverlightCreationTest, DISABLED_PerfCold) {
- RegKey silverlight_key(HKEY_CLASSES_ROOT, kSilverlightControlKey);
+ RegKey silverlight_key(HKEY_CLASSES_ROOT, kSilverlightControlKey, KEY_READ);
std::wstring plugin_path;
ASSERT_TRUE(silverlight_key.ReadValue(L"", &plugin_path));