[chromium-style] auto variable type must not deduce to a raw pointer type

This commit is contained in:
Jeremy Apthorp 2018-04-17 15:41:47 -07:00
parent 667c43398c
commit a635f078c6
61 changed files with 189 additions and 188 deletions

View file

@ -17,7 +17,7 @@ bool IsUrlArg(const base::CommandLine::CharType* arg) {
// the first character must be a letter for this to be a URL
auto c = *arg;
if (('a' <= c && c <= 'z') || ('A' <= c && c <= 'Z')) {
for (auto p = arg + 1; *p; ++p) {
for (auto* p = arg + 1; *p; ++p) {
c = *p;
// colon indicates that the argument starts with a URI scheme
@ -1377,7 +1377,7 @@ bool IsBlacklistedArg(const base::CommandLine::CharType* arg) {
static const char* prefixes[] = {"--", "-", "/"};
int prefix_length = 0;
for (auto& prefix : prefixes) {
for (auto*& prefix : prefixes) {
if (base::StartsWith(a, prefix, base::CompareCase::SENSITIVE)) {
prefix_length = strlen(prefix);
break;