mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-11 01:42:22 +03:00
Ensure that sqlite3_blob_reopen() correctly handles short rows.
Proposed fix for ticket [e6e962d6b0f06f46e]. Further testing needed. FossilOrigin-Name: 57d8dad35c2a9ab635e954dce7f3986ae1ca8ed2
This commit is contained in:
@@ -77,7 +77,9 @@ static int blobSeekToRow(Incrblob *p, sqlite3_int64 iRow, char **pzErr){
|
||||
}
|
||||
if( rc==SQLITE_ROW ){
|
||||
VdbeCursor *pC = v->apCsr[0];
|
||||
u32 type = pC->aType[p->iCol];
|
||||
u32 type = pC->nHdrParsed>p->iCol ? pC->aType[p->iCol] : 0;
|
||||
testcase( pC->nHdrParsed==p->iCol );
|
||||
testcase( pC->nHdrParsed==p->iCol+1 );
|
||||
if( type<12 ){
|
||||
zErr = sqlite3MPrintf(p->db, "cannot open value of type %s",
|
||||
type==0?"null": type==7?"real": "integer"
|
||||
|
||||
Reference in New Issue
Block a user