Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Fix another segfault that can occur following a malloc failure in the SQL compiler. (CVS 4748) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
9d98a3f0dded4ee7ed53872f48ee8592 |
User & Date: | danielk1977 2008-01-23 17:13:41.000 |
Context
2008-01-24
| ||
14:27 | Fix a segfault that may follow a malloc failure during compilation of an INSTEAD OF trigger. (CVS 4749) (check-in: c6635a71db user: danielk1977 tags: trunk) | |
2008-01-23
| ||
17:13 | Fix another segfault that can occur following a malloc failure in the SQL compiler. (CVS 4748) (check-in: 9d98a3f0dd user: danielk1977 tags: trunk) | |
15:44 | Fix a couple of segfaults that could occur after a malloc() failure in the SQL compiler. (CVS 4747) (check-in: 6bd8db3839 user: danielk1977 tags: trunk) | |
Changes
Changes to src/select.c.
︙ | |||
8 9 10 11 12 13 14 | 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | - + | ** May you find forgiveness for yourself and forgive others. ** May you share freely, never taking more than you give. ** ************************************************************************* ** This file contains C code routines that are called by the parser ** to handle SELECT statements in SQLite. ** |
︙ | |||
1672 1673 1674 1675 1676 1677 1678 | 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 | - + + - + - - - + + | } while( pSelect->pPrior ){ pSelect = pSelect->pPrior; } while( pSelect && moreToDo ){ moreToDo = 0; for(i=0; i<pOrderBy->nExpr; i++){ |
︙ |
Changes to test/malloc.test.
︙ | |||
12 13 14 15 16 17 18 | 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | - + | # This file attempts to check the behavior of the SQLite library in # an out-of-memory situation. When compiled with -DSQLITE_DEBUG=1, # the SQLite library accepts a special command (sqlite3_memdebug_fail N C) # which causes the N-th malloc to fail. This special feature is used # to see what happens in the library if a malloc were to really fail # due to an out-of-memory situation. # |
︙ | |||
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 | 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 | + + + + + + + + | } -sqlbody { SELECT * FROM abc LIMIT 10; } -cleanup { set e [db eval {PRAGMA integrity_check}] if {$e ne "ok"} {error $e} } } ifcapable compound { do_malloc_test 24 -start 19 -sqlprep { CREATE TABLE t1(a, b, c) } -sqlbody { SELECT 1 FROM t1 UNION SELECT 2 FROM t1 ORDER BY 1 } } # Ensure that no file descriptors were leaked. do_test malloc-99.X { catch {db close} set sqlite_open_file_count } {0} puts open-file-count=$sqlite_open_file_count finish_test |