mirror of
https://github.com/isar/rusqlite.git
synced 2024-11-22 16:29:20 +08:00
Increase bundled SQLite variables and depth
We've been hitting the default `MAX_VARIABLE_NUMBER` and `MAX_EXPR_DEPTH` with quite basic tests here in Prisma. I was able to run the tests by using the Arch Linux packaged libsqlite3, but when turning on the bundled version I was able to get my test to crash with this test project: https://github.com/pimeys/sqlite_parameter_test Now taking a look how Arch Linux builds sqlite, I was able to find two flags fixing the issue: https://git.archlinux.org/svntogit/packages.git/tree/trunk/PKGBUILD?h=packages/sqlite#n35 I think it would be safe to include them in rusqlite.
This commit is contained in:
parent
dfa937934d
commit
4b9295c186
@ -52,6 +52,8 @@ mod build_bundled {
|
|||||||
let mut cfg = cc::Build::new();
|
let mut cfg = cc::Build::new();
|
||||||
cfg.file("sqlite3/sqlite3.c")
|
cfg.file("sqlite3/sqlite3.c")
|
||||||
.flag("-DSQLITE_CORE")
|
.flag("-DSQLITE_CORE")
|
||||||
|
.flag("-DSQLITE_MAX_VARIABLE_NUMBER=250000")
|
||||||
|
.flag("-DSQLITE_MAX_EXPR_DEPTH=10000")
|
||||||
.flag("-DSQLITE_DEFAULT_FOREIGN_KEYS=1")
|
.flag("-DSQLITE_DEFAULT_FOREIGN_KEYS=1")
|
||||||
.flag("-DSQLITE_ENABLE_API_ARMOR")
|
.flag("-DSQLITE_ENABLE_API_ARMOR")
|
||||||
.flag("-DSQLITE_ENABLE_COLUMN_METADATA")
|
.flag("-DSQLITE_ENABLE_COLUMN_METADATA")
|
||||||
|
Loading…
Reference in New Issue
Block a user