Remove an unnecessary call to sqlite3VdbeMemExpandBlob() when casting to

text.

FossilOrigin-Name: 19e2e5950541f1a93eed994cc2b1eaf64b68e858
This commit is contained in:
drh
2016-09-09 20:23:59 +00:00
parent 64caee4086
commit 27fe1c3fcc
3 changed files with 8 additions and 11 deletions
+1 -4
View File
@@ -575,7 +575,7 @@ int sqlite3VdbeMemNumerify(Mem *pMem){
}
}
assert( (pMem->flags & (MEM_Int|MEM_Real|MEM_Null))!=0 );
pMem->flags &= ~(MEM_Str|MEM_Blob);
pMem->flags &= ~(MEM_Str|MEM_Blob|MEM_Zero);
return SQLITE_OK;
}
@@ -1018,9 +1018,6 @@ static SQLITE_NOINLINE const void *valueToText(sqlite3_value* pVal, u8 enc){
assert( (pVal->flags & (MEM_Null))==0 );
if( pVal->flags & (MEM_Blob|MEM_Str) ){
pVal->flags |= MEM_Str;
if( pVal->flags & MEM_Zero ){
sqlite3VdbeMemExpandBlob(pVal);
}
if( pVal->enc != (enc & ~SQLITE_UTF16_ALIGNED) ){
sqlite3VdbeChangeEncoding(pVal, enc & ~SQLITE_UTF16_ALIGNED);
}