| Index: sandbox/win/src/sandbox_utils.h
|
| diff --git a/sandbox/win/src/sandbox_utils.h b/sandbox/win/src/sandbox_utils.h
|
| index 78e76fbc733b390bcb4875f358b2adecaaa34989..55eee5217003881807c7511dcc927c1b5ee2bbb3 100644
|
| --- a/sandbox/win/src/sandbox_utils.h
|
| +++ b/sandbox/win/src/sandbox_utils.h
|
| @@ -1,27 +1,43 @@
|
| -// Copyright (c) 2011 The Chromium Authors. All rights reserved.
|
| +// Copyright 2013 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.
|
|
|
| -#ifndef SANDBOX_SRC_SANDBOX_UTILS_H__
|
| -#define SANDBOX_SRC_SANDBOX_UTILS_H__
|
| -
|
| -#include <windows.h>
|
| -#include <string>
|
| +#ifndef SANDBOX_SRC_SANDBOX_UTILS_H_
|
| +#define SANDBOX_SRC_SANDBOX_UTILS_H_
|
|
|
| #include "base/basictypes.h"
|
| +#include "base/strings/string16.h"
|
| #include "sandbox/win/src/nt_internals.h"
|
|
|
| namespace sandbox {
|
|
|
| +// Returns a pointer to the IPC shared memory.
|
| +void* GetGlobalIPCMemory();
|
| +
|
| +// Returns a pointer to the Policy shared memory.
|
| +void* GetGlobalPolicyMemory();
|
| +
|
| +// Copies data from a user buffer to our buffer. Returns the operation status.
|
| +NTSTATUS CopyData(void* destination, const void* source, size_t bytes);
|
| +
|
| +// Copies the name from an object attributes.
|
| +NTSTATUS AllocAndCopyName(const OBJECT_ATTRIBUTES* in_object,
|
| + wchar_t** out_name, uint32* attributes, HANDLE* root);
|
| +// Returns the last component of a path that contains the module name.
|
| +// It will return NULL if the path ends with the path separator. The returned
|
| +// buffer must be freed with a placement delete (see GetImageNameFromModule
|
| +// example).
|
| +UNICODE_STRING* ExtractModuleName(const UNICODE_STRING* module_path);
|
| +
|
| // Returns true if the current OS is Windows XP SP2 or later.
|
| bool IsXPSP2OrLater();
|
|
|
| -void InitObjectAttribs(const std::wstring& name,
|
| +void InitObjectAttribs(const string16& name,
|
| ULONG attributes,
|
| HANDLE root,
|
| OBJECT_ATTRIBUTES* obj_attr,
|
| UNICODE_STRING* uni_name);
|
|
|
| -}; // namespace sandbox
|
| +} // namespace sandbox
|
|
|
| -#endif // SANDBOX_SRC_SANDBOX_UTILS_H__
|
| +#endif // SANDBOX_SRC_SANDBOX_UTILS_H_
|
|
|