| Index: third_party/sqlite/patches/0003-backport-SQLite-memcmp-patch.patch
|
| diff --git a/third_party/sqlite/memcmp.patch b/third_party/sqlite/patches/0003-backport-SQLite-memcmp-patch.patch
|
| similarity index 53%
|
| rename from third_party/sqlite/memcmp.patch
|
| rename to third_party/sqlite/patches/0003-backport-SQLite-memcmp-patch.patch
|
| index ff562e822dbb407b488b95afcdacdcdade92a6cd..724145fe68d41407a05467b9dce7118957278052 100644
|
| --- a/third_party/sqlite/memcmp.patch
|
| +++ b/third_party/sqlite/patches/0003-backport-SQLite-memcmp-patch.patch
|
| @@ -1,15 +1,29 @@
|
| -http://crbug.com/178677 refers to potential buffer overruns in ASAN
|
| -due to memcmp() being used instead of strcmp() in SQLite. Reported to
|
| -SQLite team, resulting in http://www.sqlite.org/src/info/d73435587b .
|
| -This was backported into Chromium's version of SQLite, then this file
|
| -was generated using:
|
| - git diff --relative=third_party/sqlite/src --src-prefix='' --dst-prefix='' > third_party/sqlite/memcmp.patch
|
| +From cd23f4b26a4575353589a97f039accb2c8ec5143 Mon Sep 17 00:00:00 2001
|
| +From: Scott Hess <shess@chromium.org>
|
| +Date: Fri, 10 May 2013 02:52:43 +0000
|
| +Subject: [PATCH 03/23] [backport] SQLite memcmp patch.
|
|
|
| +http://www.sqlite.org/src/info/d73435587b
|
|
|
| -diff --git src/analyze.c src/analyze.c
|
| +Verified that the amalgamation came out with all the right patches by
|
| +comparing the amalgamation diff to the appropriately-ordered diffs of
|
| +the original files.
|
| +
|
| +BUG=178677
|
| +
|
| +Original review URL: https://chromiumcodereview.appspot.com/15070002
|
| +---
|
| + third_party/sqlite/src/src/analyze.c | 4 ++--
|
| + third_party/sqlite/src/src/build.c | 2 +-
|
| + third_party/sqlite/src/src/expr.c | 4 +---
|
| + third_party/sqlite/src/src/os_unix.c | 2 +-
|
| + third_party/sqlite/src/src/vdbeapi.c | 2 +-
|
| + 5 files changed, 6 insertions(+), 8 deletions(-)
|
| +
|
| +diff --git a/third_party/sqlite/src/src/analyze.c b/third_party/sqlite/src/src/analyze.c
|
| index 17c1de8..2444e74 100644
|
| ---- src/analyze.c
|
| -+++ src/analyze.c
|
| +--- a/third_party/sqlite/src/src/analyze.c
|
| ++++ b/third_party/sqlite/src/src/analyze.c
|
| @@ -142,7 +142,7 @@ static void analyzeOneTable(
|
| /* Do not gather statistics on views or virtual tables */
|
| return;
|
| @@ -28,11 +42,11 @@ index 17c1de8..2444e74 100644
|
| pIndex->bUnordered = 1;
|
| break;
|
| }
|
| -diff --git src/build.c src/build.c
|
| -index 323a616..4f4f8ed 100644
|
| ---- src/build.c
|
| -+++ src/build.c
|
| -@@ -2480,7 +2480,7 @@ Index *sqlite3CreateIndex(
|
| +diff --git a/third_party/sqlite/src/src/build.c b/third_party/sqlite/src/src/build.c
|
| +index 83a1db8..25a74ca 100644
|
| +--- a/third_party/sqlite/src/src/build.c
|
| ++++ b/third_party/sqlite/src/src/build.c
|
| +@@ -2477,7 +2477,7 @@ Index *sqlite3CreateIndex(
|
| assert( pTab!=0 );
|
| assert( pParse->nErr==0 );
|
| if( sqlite3StrNICmp(pTab->zName, "sqlite_", 7)==0
|
| @@ -41,10 +55,10 @@ index 323a616..4f4f8ed 100644
|
| sqlite3ErrorMsg(pParse, "table %s may not be indexed", pTab->zName);
|
| goto exit_create_index;
|
| }
|
| -diff --git src/expr.c src/expr.c
|
| +diff --git a/third_party/sqlite/src/src/expr.c b/third_party/sqlite/src/src/expr.c
|
| index 2699ae1..9d1193b 100644
|
| ---- src/expr.c
|
| -+++ src/expr.c
|
| +--- a/third_party/sqlite/src/src/expr.c
|
| ++++ b/third_party/sqlite/src/src/expr.c
|
| @@ -578,12 +578,10 @@ void sqlite3ExprAssignVarNumber(Parse *pParse, Expr *pExpr){
|
| ** has never appeared before, reuse the same variable number
|
| */
|
| @@ -59,23 +73,23 @@ index 2699ae1..9d1193b 100644
|
| pExpr->iColumn = pE->iColumn;
|
| break;
|
| }
|
| -diff --git src/os_unix.c src/os_unix.c
|
| -index 804c588..77ffd8a 100644
|
| ---- src/os_unix.c
|
| -+++ src/os_unix.c
|
| -@@ -4506,7 +4506,7 @@ int fillInUnixFile(
|
| - OSTRACE(("OPEN %-3d %s\n", h, zFilename));
|
| +diff --git a/third_party/sqlite/src/src/os_unix.c b/third_party/sqlite/src/src/os_unix.c
|
| +index 2626ab4..998e353 100644
|
| +--- a/third_party/sqlite/src/src/os_unix.c
|
| ++++ b/third_party/sqlite/src/src/os_unix.c
|
| +@@ -4456,7 +4456,7 @@ static int fillInUnixFile(
|
| pNew->h = h;
|
| + pNew->dirfd = dirfd;
|
| pNew->zPath = zFilename;
|
| - if( memcmp(pVfs->zName,"unix-excl",10)==0 ){
|
| + if( strcmp(pVfs->zName,"unix-excl")==0 ){
|
| pNew->ctrlFlags = UNIXFILE_EXCL;
|
| }else{
|
| pNew->ctrlFlags = 0;
|
| -diff --git src/vdbeapi.c src/vdbeapi.c
|
| +diff --git a/third_party/sqlite/src/src/vdbeapi.c b/third_party/sqlite/src/src/vdbeapi.c
|
| index 90baacc..80ceb9f 100644
|
| ---- src/vdbeapi.c
|
| -+++ src/vdbeapi.c
|
| +--- a/third_party/sqlite/src/src/vdbeapi.c
|
| ++++ b/third_party/sqlite/src/src/vdbeapi.c
|
| @@ -1222,7 +1222,7 @@ int sqlite3VdbeParameterIndex(Vdbe *p, const char *zName, int nName){
|
| if( zName ){
|
| for(i=0; i<p->nVar; i++){
|
| @@ -85,3 +99,6 @@ index 90baacc..80ceb9f 100644
|
| return i+1;
|
| }
|
| }
|
| +--
|
| +2.2.1
|
| +
|
|
|