diff options
author | drh <drh@noemail.net> | 2013-09-06 13:10:12 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2013-09-06 13:10:12 +0000 |
commit | d36e1041120280adfc9612d8f6e4ade318b3ffa0 (patch) | |
tree | 30833e18e2ea6dd6a9d39a40c19e8f0c748f9c3d /src/callback.c | |
parent | 0d31dc37ac2a659fca1058c16928a29ccaca3ab4 (diff) | |
download | sqlite-d36e1041120280adfc9612d8f6e4ade318b3ffa0.tar.gz sqlite-d36e1041120280adfc9612d8f6e4ade318b3ffa0.zip |
Combine the FuncDef.iPrefEnc and FuncDef.flags fields into a single
new FuncDef.funcFlags field.
FossilOrigin-Name: 97b10e66e98e84755aa577f8da017bf1aea2056c
Diffstat (limited to 'src/callback.c')
-rw-r--r-- | src/callback.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/callback.c b/src/callback.c index d40c65cb9..66fa49089 100644 --- a/src/callback.c +++ b/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 */ } @@ -406,7 +406,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); |