]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-44329: Refactor sqlite3 statement creation (GH-26566)
authorErlend Egeberg Aasland <erlend.aasland@innova.no>
Tue, 8 Jun 2021 15:00:56 +0000 (17:00 +0200)
committerGitHub <noreply@github.com>
Tue, 8 Jun 2021 15:00:56 +0000 (16:00 +0100)
commit1c02655fb08043b3027748ca1179c416c21a4277
tree3124796b69e7fac7a0100299f7705ac928a474b1
parent3fe921cd49959181163671364c8b84faa88f7895
bpo-44329: Refactor sqlite3 statement creation (GH-26566)

Call SQLite API's first, and return early in case of error. At the end,
allocate the object and initialise members. We now avoid unneeded
alloc/dealloc's in case the statement creation fails.
Modules/_sqlite/statement.c