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

Manually preserve cconvert values until sqlite3_step #308

Merged
merged 1 commit into from
Nov 17, 2022

Commits on Nov 17, 2022

  1. Manually preserve cconvert values until sqlite3_step

    Fixes #306.
    
    The core issue here is that when we `bind!` some values to an insert
    statement, the _cconvert_ed value needs to remain valid (i.e. not
    GC-able) until we execute the insert statement in `sqlite3_step`.
    In each `SQLite.Stmt`, we have a `params` field for storing these
    values, but we weren't accounting for the fact that some values,
    (in the original issue case, InlineStrings), may be `cconvert`ed
    to a different value when they're actually bound, and it's the cconverted
    value that we need to store in `params` until the statement is executed.
    quinnj committed Nov 17, 2022
    Configuration menu
    Copy the full SHA
    f7204f7 View commit details
    Browse the repository at this point in the history