Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ede52bc

Browse filesBrowse files
geeksilva97aduh95
authored andcommitted
src,sqlite: fix filterFunc dangling reference
PR-URL: #62281 Reviewed-By: René <contact.9a5d6388@renegade334.me.uk> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
1 parent b800c57 commit ede52bc
Copy full SHA for ede52bc

1 file changed

+2-1Lines changed: 2 additions & 1 deletion

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/node_sqlite.cc‎

Copy file name to clipboardExpand all lines: src/node_sqlite.cc
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2157,7 +2157,8 @@ void DatabaseSync::ApplyChangeset(const FunctionCallbackInfo<Value>& args) {
21572157

21582158
Local<Function> filterFunc = filterValue.As<Function>();
21592159

2160-
context.filterCallback = [&](std::string_view item) -> bool {
2160+
context.filterCallback =
2161+
[env, db, filterFunc](std::string_view item) -> bool {
21612162
// If there was an error in the previous call to the filter's
21622163
// callback, we skip calling it again.
21632164
if (db->ignore_next_sqlite_error_) {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.