Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory leak when using Statement.expanded_sql #552

Closed
a9y opened this issue Jul 28, 2019 · 2 comments
Closed

Memory leak when using Statement.expanded_sql #552

a9y opened this issue Jul 28, 2019 · 2 comments
Labels

Comments

@a9y
Copy link

a9y commented Jul 28, 2019

The string returned by sqlite3_expanded_sql allocates memory but the Statement (and RawStatement) interface makes no attempt to free it.

@gwenn
Copy link
Collaborator

gwenn commented Jul 28, 2019

http://sqlite.org/c3ref/expanded_sql.html

The string returned by sqlite3_expanded_sql(P), on the other hand, is obtained from sqlite3_malloc() and must be free by the application by passing it to sqlite3_free().

@gwenn
Copy link
Collaborator

gwenn commented Dec 13, 2019

Fixed in 0.21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants