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

Side by Side Diff: sandbox/win/src/policy_engine_opcodes.cc

Issue 10783004: Move Windows Sandbox, trybots version (don't commit me!) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase to top of tree Created 8 years, 5 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 | « sandbox/win/src/policy_engine_opcodes.h ('k') | sandbox/win/src/policy_engine_params.h » ('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 "sandbox/src/policy_engine_opcodes.h" 5 #include "sandbox/win/src/policy_engine_opcodes.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "sandbox/src/sandbox_nt_types.h" 8 #include "sandbox/win/src/sandbox_nt_types.h"
9 #include "sandbox/src/sandbox_types.h" 9 #include "sandbox/win/src/sandbox_types.h"
10 10
11 namespace { 11 namespace {
12 const unsigned short kMaxUniStrSize = 0xfffc; 12 const unsigned short kMaxUniStrSize = 0xfffc;
13 13
14 bool InitStringUnicode(const wchar_t* source, size_t length, 14 bool InitStringUnicode(const wchar_t* source, size_t length,
15 UNICODE_STRING* ustring) { 15 UNICODE_STRING* ustring) {
16 ustring->Buffer = const_cast<wchar_t*>(source); 16 ustring->Buffer = const_cast<wchar_t*>(source);
17 ustring->Length = static_cast<USHORT>(length) * sizeof(wchar_t); 17 ustring->Length = static_cast<USHORT>(length) * sizeof(wchar_t);
18 if (length > kMaxUniStrSize) { 18 if (length > kMaxUniStrSize) {
19 return false; 19 return false;
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after
445 OPCODE_EVAL(OP_ULONG_AND_MATCH, this, parameters, match); 445 OPCODE_EVAL(OP_ULONG_AND_MATCH, this, parameters, match);
446 OPCODE_EVAL(OP_ACTION, this, parameters, match); 446 OPCODE_EVAL(OP_ACTION, this, parameters, match);
447 default: 447 default:
448 return EVAL_ERROR; 448 return EVAL_ERROR;
449 } 449 }
450 } 450 }
451 451
452 #undef OPCODE_EVAL 452 #undef OPCODE_EVAL
453 453
454 } // namespace sandbox 454 } // namespace sandbox
OLDNEW
« no previous file with comments | « sandbox/win/src/policy_engine_opcodes.h ('k') | sandbox/win/src/policy_engine_params.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698