summaryrefslogtreecommitdiffstats
path: root/base/win
diff options
context:
space:
mode:
authordavidben <davidben@chromium.org>2015-11-19 11:07:06 -0800
committerCommit bot <commit-bot@chromium.org>2015-11-19 19:08:51 +0000
commit4507eaa1a845d080078f4e3e5ee2dd2bb1716e3e (patch)
tree79d04a6e3d605da192985c144c875ebe9855ebb8 /base/win
parent119d0f4fe5ffa8463cb49ac8512cb04e07fd2c1c (diff)
downloadchromium_src-4507eaa1a845d080078f4e3e5ee2dd2bb1716e3e.zip
chromium_src-4507eaa1a845d080078f4e3e5ee2dd2bb1716e3e.tar.gz
chromium_src-4507eaa1a845d080078f4e3e5ee2dd2bb1716e3e.tar.bz2
Make vector_as_array use std::vector::data and switch a few directories.
Get //base and //crypto. This revealed an IWYU problem in //components/policy, so go and convert that too. BUG=556678 Review URL: https://codereview.chromium.org/1441543002 Cr-Commit-Position: refs/heads/master@{#360639}
Diffstat (limited to 'base/win')
-rw-r--r--base/win/registry.cc4
-rw-r--r--base/win/registry.h3
2 files changed, 3 insertions, 4 deletions
diff --git a/base/win/registry.cc b/base/win/registry.cc
index ea96e67..5d75c96 100644
--- a/base/win/registry.cc
+++ b/base/win/registry.cc
@@ -569,7 +569,7 @@ bool RegistryValueIterator::Read() {
value_size_ = static_cast<DWORD>((value_.size() - 1) * sizeof(wchar_t));
LONG result = ::RegEnumValue(
key_, index_, WriteInto(&name_, name_size), &name_size, NULL, &type_,
- reinterpret_cast<BYTE*>(vector_as_array(&value_)), &value_size_);
+ reinterpret_cast<BYTE*>(value_.data()), &value_size_);
if (result == ERROR_MORE_DATA) {
// Registry key names are limited to 255 characters and fit within
@@ -585,7 +585,7 @@ bool RegistryValueIterator::Read() {
name_size = name_size == capacity ? MAX_REGISTRY_NAME_SIZE : capacity;
result = ::RegEnumValue(
key_, index_, WriteInto(&name_, name_size), &name_size, NULL, &type_,
- reinterpret_cast<BYTE*>(vector_as_array(&value_)), &value_size_);
+ reinterpret_cast<BYTE*>(value_.data()), &value_size_);
}
if (result == ERROR_SUCCESS) {
diff --git a/base/win/registry.h b/base/win/registry.h
index c3e015b..83f354d 100644
--- a/base/win/registry.h
+++ b/base/win/registry.h
@@ -11,7 +11,6 @@
#include "base/base_export.h"
#include "base/basictypes.h"
-#include "base/stl_util.h"
#include "base/win/object_watcher.h"
#include "base/win/scoped_handle.h"
@@ -180,7 +179,7 @@ class BASE_EXPORT RegistryValueIterator {
void operator++();
const wchar_t* Name() const { return name_.c_str(); }
- const wchar_t* Value() const { return vector_as_array(&value_); }
+ const wchar_t* Value() const { return value_.data(); }
// ValueSize() is in bytes.
DWORD ValueSize() const { return value_size_; }
DWORD Type() const { return type_; }