| OLD | NEW |
| 1 // Copyright (c) 2006-2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/service_resolver.h" | 5 #include "sandbox/src/service_resolver.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | |
| 8 #include "base/scoped_ptr.h" | 7 #include "base/scoped_ptr.h" |
| 9 #include "sandbox/src/sandbox_utils.h" | 8 #include "sandbox/src/sandbox_utils.h" |
| 10 #include "sandbox/src/win_utils.h" | 9 #include "sandbox/src/win_utils.h" |
| 11 | 10 |
| 12 namespace { | 11 namespace { |
| 13 #pragma pack(push, 1) | 12 #pragma pack(push, 1) |
| 14 | 13 |
| 15 const BYTE kMovEax = 0xB8; | 14 const BYTE kMovEax = 0xB8; |
| 16 const BYTE kMovEdx = 0xBA; | 15 const BYTE kMovEdx = 0xBA; |
| 17 const USHORT kCallPtrEdx = 0x12FF; | 16 const USHORT kCallPtrEdx = 0x12FF; |
| (...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 function_code.service_id > kMaxService) | 331 function_code.service_id > kMaxService) |
| 333 return false; | 332 return false; |
| 334 | 333 |
| 335 // Save the verified code | 334 // Save the verified code |
| 336 memcpy(local_thunk, &function_code, sizeof(function_code)); | 335 memcpy(local_thunk, &function_code, sizeof(function_code)); |
| 337 | 336 |
| 338 return true; | 337 return true; |
| 339 } | 338 } |
| 340 | 339 |
| 341 } // namespace sandbox | 340 } // namespace sandbox |
| OLD | NEW |