fix sqlite porting bug
This commit is contained in:
Родитель
7143eab384
Коммит
ef124013a5
|
@ -81,7 +81,7 @@ int main(){
|
|||
RUN("BEGIN;");
|
||||
|
||||
// 25000 INSERTs in a transaction
|
||||
for (i = 0; i < 5; i++) {
|
||||
for (i = 0; i < 78; i++) {
|
||||
RUN("INSERT INTO t1 VALUES(1,12345,'one 1 one 1 one 1');");
|
||||
RUN("INSERT INTO t1 VALUES(2,23422,'two two two two');");
|
||||
RUN("INSERT INTO t1 VALUES(3,31233,'three three 33333333333 three');");
|
||||
|
|
|
@ -52942,7 +52942,12 @@ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){
|
|||
endPtr = &data[pPage->cellOffset + 2*pPage->nCell - 2];
|
||||
assert( (SQLITE_PTR_TO_INT(ptr)&1)==0 ); /* ptr is always 2-byte aligned */
|
||||
while( ptr<endPtr ){
|
||||
#ifdef EMSCRIPTEN
|
||||
ptr[0] = ptr[2];
|
||||
ptr[1] = ptr[3];
|
||||
#else
|
||||
*(u16*)ptr = *(u16*)&ptr[2];
|
||||
#endif
|
||||
ptr += 2;
|
||||
}
|
||||
pPage->nCell--;
|
||||
|
|
Загрузка…
Ссылка в новой задаче