diff options
author | 2014-03-24 01:37:28 +0000 | |
---|---|---|
committer | 2014-03-24 01:37:28 +0000 | |
commit | 29ebcee2452a131560f5220abaf585648f84ce40 (patch) | |
tree | 844ef4fe135beff619b9e7b632f3b6722d6367e4 /lib/libsqlite3/src/callback.c | |
parent | annotate some packed structures with the alignment the hardware (diff) | |
download | wireguard-openbsd-29ebcee2452a131560f5220abaf585648f84ce40.tar.xz wireguard-openbsd-29ebcee2452a131560f5220abaf585648f84ce40.zip |
Update sqlite to 3.8.4. A list of changes are available here:
http://sqlite.org/changes.html.
Tested in a bulk and ok landry@
Diffstat (limited to 'lib/libsqlite3/src/callback.c')
-rw-r--r-- | lib/libsqlite3/src/callback.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/libsqlite3/src/callback.c b/lib/libsqlite3/src/callback.c index d40c65cb924..260fe806bb4 100644 --- a/lib/libsqlite3/src/callback.c +++ b/lib/libsqlite3/src/callback.c @@ -270,9 +270,9 @@ static int matchQuality( } /* Bonus points if the text encoding matches */ - if( enc==p->iPrefEnc ){ + if( enc==(p->funcFlags & SQLITE_FUNC_ENCMASK) ){ match += 2; /* Exact encoding match */ - }else if( (enc & p->iPrefEnc & 2)!=0 ){ + }else if( (enc & p->funcFlags & 2)!=0 ){ match += 1; /* Both are UTF16, but with different byte orders */ } @@ -357,7 +357,6 @@ FuncDef *sqlite3FindFunction( assert( nArg>=(-2) ); assert( nArg>=(-1) || createFlag==0 ); - assert( enc==SQLITE_UTF8 || enc==SQLITE_UTF16LE || enc==SQLITE_UTF16BE ); h = (sqlite3UpperToLower[(u8)zName[0]] + nName) % ArraySize(db->aFunc.a); /* First search for a match amongst the application-defined functions. @@ -406,7 +405,7 @@ FuncDef *sqlite3FindFunction( (pBest = sqlite3DbMallocZero(db, sizeof(*pBest)+nName+1))!=0 ){ pBest->zName = (char *)&pBest[1]; pBest->nArg = (u16)nArg; - pBest->iPrefEnc = enc; + pBest->funcFlags = enc; memcpy(pBest->zName, zName, nName); pBest->zName[nName] = 0; sqlite3FuncDefInsert(&db->aFunc, pBest); |