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

Side by Side Diff: chrome/browser/sandbox_policy.cc

Issue 28128: Fix all places where we used the GetWinVersion function... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/importer/ie_importer.cc ('k') | chrome/browser/shell_integration.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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #include "chrome/browser/sandbox_policy.h" 5 #include "chrome/browser/sandbox_policy.h"
6 6
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/registry.h" 10 #include "base/registry.h"
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 if (!AddDirectoryAndChildren(base::DIR_LOCAL_APP_DATA, NULL, 275 if (!AddDirectoryAndChildren(base::DIR_LOCAL_APP_DATA, NULL,
276 sandbox::TargetPolicy::FILES_ALLOW_READONLY, 276 sandbox::TargetPolicy::FILES_ALLOW_READONLY,
277 policy)) 277 policy))
278 return false; 278 return false;
279 279
280 if (!AddKeyAndSubkeys(L"HKEY_CURRENT_USER\\SOFTWARE\\MACROMEDIA", 280 if (!AddKeyAndSubkeys(L"HKEY_CURRENT_USER\\SOFTWARE\\MACROMEDIA",
281 sandbox::TargetPolicy::REG_ALLOW_ANY, 281 sandbox::TargetPolicy::REG_ALLOW_ANY,
282 policy)) 282 policy))
283 return false; 283 return false;
284 284
285 if (win_util::GetWinVersion() == win_util::WINVERSION_VISTA) { 285 if (win_util::GetWinVersion() >= win_util::WINVERSION_VISTA) {
286 if (!AddKeyAndSubkeys(L"HKEY_CURRENT_USER\\SOFTWARE\\AppDataLow", 286 if (!AddKeyAndSubkeys(L"HKEY_CURRENT_USER\\SOFTWARE\\AppDataLow",
287 sandbox::TargetPolicy::REG_ALLOW_ANY, 287 sandbox::TargetPolicy::REG_ALLOW_ANY,
288 policy)) 288 policy))
289 return false; 289 return false;
290 290
291 if (!AddDirectoryAndChildren(base::DIR_LOCAL_APP_DATA_LOW, NULL, 291 if (!AddDirectoryAndChildren(base::DIR_LOCAL_APP_DATA_LOW, NULL,
292 sandbox::TargetPolicy::FILES_ALLOW_ANY, 292 sandbox::TargetPolicy::FILES_ALLOW_ANY,
293 policy)) 293 policy))
294 return false; 294 return false;
295 } 295 }
(...skipping 23 matching lines...) Expand all
319 return ApplyPolicyForTrustedPlugin(policy); 319 return ApplyPolicyForTrustedPlugin(policy);
320 case PLUGIN_GROUP_UNTRUSTED: 320 case PLUGIN_GROUP_UNTRUSTED:
321 return ApplyPolicyForUntrustedPlugin(policy); 321 return ApplyPolicyForUntrustedPlugin(policy);
322 default: 322 default:
323 NOTREACHED(); 323 NOTREACHED();
324 break; 324 break;
325 } 325 }
326 326
327 return false; 327 return false;
328 } 328 }
OLDNEW
« no previous file with comments | « chrome/browser/importer/ie_importer.cc ('k') | chrome/browser/shell_integration.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698