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

Side by Side Diff: sql/connection.cc

Issue 1224553010: Replace base::str[n]casecmp with helper functions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« no previous file with comments | « skia/ext/image_operations_bench.cc ('k') | tools/gn/filesystem_utils.cc » ('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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "sql/connection.h" 5 #include "sql/connection.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/files/file_util.h" 10 #include "base/files/file_util.h"
(...skipping 974 matching lines...) Expand 10 before | Expand all | Expand 10 after
985 sql.append(")"); 985 sql.append(")");
986 986
987 Statement statement(GetUntrackedStatement(sql.c_str())); 987 Statement statement(GetUntrackedStatement(sql.c_str()));
988 988
989 // This can happen if the database is corrupt and the error is being ignored 989 // This can happen if the database is corrupt and the error is being ignored
990 // for testing purposes. 990 // for testing purposes.
991 if (!statement.is_valid()) 991 if (!statement.is_valid())
992 return false; 992 return false;
993 993
994 while (statement.Step()) { 994 while (statement.Step()) {
995 if (!base::strcasecmp(statement.ColumnString(1).c_str(), column_name)) 995 if (base::EqualsCaseInsensitiveASCII(statement.ColumnString(1),
996 column_name))
996 return true; 997 return true;
997 } 998 }
998 return false; 999 return false;
999 } 1000 }
1000 1001
1001 int64_t Connection::GetLastInsertRowId() const { 1002 int64_t Connection::GetLastInsertRowId() const {
1002 if (!db_) { 1003 if (!db_) {
1003 DLOG_IF(FATAL, !poisoned_) << "Illegal use of connection without a db"; 1004 DLOG_IF(FATAL, !poisoned_) << "Illegal use of connection without a db";
1004 return 0; 1005 return 0;
1005 } 1006 }
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after
1336 ignore_result(Execute(kNoWritableSchema)); 1337 ignore_result(Execute(kNoWritableSchema));
1337 1338
1338 return ret; 1339 return ret;
1339 } 1340 }
1340 1341
1341 base::TimeTicks TimeSource::Now() { 1342 base::TimeTicks TimeSource::Now() {
1342 return base::TimeTicks::Now(); 1343 return base::TimeTicks::Now();
1343 } 1344 }
1344 1345
1345 } // namespace sql 1346 } // namespace sql
OLDNEW
« no previous file with comments | « skia/ext/image_operations_bench.cc ('k') | tools/gn/filesystem_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698