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

SQLite3 desctrutor is declared as noexcept(true), but it can throw an exception #2012

Open
ppisar opened this issue Jan 16, 2025 · 0 comments
Labels
Priority: MEDIUM Triaged Someone on the DNF 5 team has read the issue and determined the next steps to take

Comments

@ppisar
Copy link
Contributor

ppisar commented Jan 16, 2025

DNF5 suffers from the same issue as libdnf rpm-software-management/libdnf#1686:

SQLite3 destructor defined in libdnf5/utils/sqlite3/sqlite3.hpp has interface implicitly noexcept(true), but in reality the implementation calls SQLite3::close() which throws SQLite3SQLError.

We should hide the exception, ideally log the exception message, and review all places of destroying SQLite3 to close the database explicitly.

@ppisar ppisar added Priority: MEDIUM Triaged Someone on the DNF 5 team has read the issue and determined the next steps to take labels Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: MEDIUM Triaged Someone on the DNF 5 team has read the issue and determined the next steps to take
Projects
None yet
Development

No branches or pull requests

1 participant