Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.1:Update
clementine
delete_the_allocated_memory_in_respective_destr...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File delete_the_allocated_memory_in_respective_destructors.patch of Package clementine
--- ext/libclementine-tagreader/tagreader.cpp | 6 ++++++ ext/libclementine-tagreader/tagreader.h | 1 + src/core/database.cpp | 5 ++++- src/songinfo/ultimatelyricsprovider.cpp | 5 +++++ src/songinfo/ultimatelyricsprovider.h | 1 + 5 files changed, 17 insertions(+), 1 deletion(-) --- a/ext/libclementine-tagreader/tagreader.cpp +++ b/ext/libclementine-tagreader/tagreader.cpp @@ -125,6 +125,12 @@ TagReader::TagReader() network_(new QNetworkAccessManager), kEmbeddedCover("(embedded)") {} +TagReader::~TagReader() +{ + delete factory_; + delete network_; +} + void TagReader::ReadFile(const QString& filename, pb::tagreader::SongMetadata* song) const { const QByteArray url(QUrl::fromLocalFile(filename).toEncoded()); --- a/ext/libclementine-tagreader/tagreader.h +++ b/ext/libclementine-tagreader/tagreader.h @@ -50,6 +50,7 @@ class FileRefFactory; class TagReader { public: TagReader(); + ~TagReader(); void ReadFile(const QString& filename, pb::tagreader::SongMetadata* song) const; --- a/src/core/database.cpp +++ b/src/core/database.cpp @@ -670,10 +670,12 @@ void Database::BackupFile(const QString& sqlite3* source_connection = nullptr; sqlite3* dest_connection = nullptr; - BOOST_SCOPE_EXIT((source_connection)(dest_connection)(task_id)(app_)) { + BOOST_SCOPE_EXIT((&source_connection)(&dest_connection)(task_id)(app_)) { // Harmless to call sqlite3_close() with a nullptr pointer. sqlite3_close(source_connection); sqlite3_close(dest_connection); + qLog(Debug) << "Closed databases after backup" << source_connection << + dest_connection; app_->task_manager()->SetTaskFinished(task_id); } BOOST_SCOPE_EXIT_END @@ -709,4 +711,5 @@ void Database::BackupFile(const QString& } sqlite3_backup_finish(backup); + qLog(Debug) << "Database backup finished"; } --- a/src/songinfo/ultimatelyricsprovider.cpp +++ b/src/songinfo/ultimatelyricsprovider.cpp @@ -34,6 +34,11 @@ UltimateLyricsProvider::UltimateLyricsPr redirect_count_(0), url_hop_(false) {} +UltimateLyricsProvider::~UltimateLyricsProvider() +{ + delete network_; +} + void UltimateLyricsProvider::FetchInfo(int id, const Song& metadata) { // Get the text codec const QTextCodec* codec = --- a/src/songinfo/ultimatelyricsprovider.h +++ b/src/songinfo/ultimatelyricsprovider.h @@ -33,6 +33,7 @@ class UltimateLyricsProvider : public So public: UltimateLyricsProvider(); + ~UltimateLyricsProvider(); static const int kRedirectLimit;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor