Skip to content

Commit

Permalink
Merge pull request duckdb#8207 from krlmlr/b-copy-string
Browse files Browse the repository at this point in the history
R: Avoid crash when finalizing
  • Loading branch information
Mytherin authored and krlmlr committed Aug 21, 2023
1 parent 3447245 commit 9c2d16f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tools/rpkg/src/connection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using namespace duckdb;

void duckdb::ConnDeleter(ConnWrapper *conn) {
cpp11::warning("Connection is garbage-collected, use dbDisconnect() to avoid this.");
cpp11::warning(std::string("Connection is garbage-collected, use dbDisconnect() to avoid this."));
delete conn;
}

Expand Down
4 changes: 2 additions & 2 deletions tools/rpkg/src/database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
using namespace duckdb;

void duckdb::DBDeleter(DBWrapper *db) {
cpp11::warning("Database is garbage-collected, use dbDisconnect(con, shutdown=TRUE) or "
"duckdb::duckdb_shutdown(drv) to avoid this.");
cpp11::warning(std::string("Database is garbage-collected, use dbDisconnect(con, shutdown=TRUE) or "
"duckdb::duckdb_shutdown(drv) to avoid this."));
delete db;
}

Expand Down

0 comments on commit 9c2d16f

Please sign in to comment.