Hello community, here is the log from the commit of package clementine for openSUSE:Factory checked in at 2019-07-23 22:38:02 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/clementine (Old) and /work/SRC/openSUSE:Factory/.clementine.new.4126 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "clementine" Tue Jul 23 22:38:02 2019 rev:52 rq:717812 version:1.3.1+git20190713 Changes: -------- --- /work/SRC/openSUSE:Factory/clementine/clementine.changes 2019-07-22 12:19:57.623671137 +0200 +++ /work/SRC/openSUSE:Factory/.clementine.new.4126/clementine.changes 2019-07-23 22:38:04.026962842 +0200 @@ -1,0 +2,10 @@ +Tue Jul 23 08:15:30 UTC 2019 - Dave Plater <[email protected]> + +- Updated memory leak patch (boo#114144): + delete_the_allocated_memory_in_respective_destructors.patch +- Fixed boo#1137785 with upstream patch from git: + 0001-Fix-crash-in-messagereply-6372.patch +- Added patch from git: + 0001-Introduce-limit-for-number-of-tag-client-processes.patch + +------------------------------------------------------------------- New: ---- 0001-Fix-crash-in-messagereply-6372.patch 0001-Introduce-limit-for-number-of-tag-client-processes.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ clementine.spec ++++++ --- /var/tmp/diff_new_pack.tkSVCX/_old 2019-07-23 22:38:05.838962468 +0200 +++ /var/tmp/diff_new_pack.tkSVCX/_new 2019-07-23 22:38:05.858962464 +0200 @@ -64,7 +64,12 @@ Patch18: 0001-Simplify-some-statements.patch Patch19: 0001-Set-non-zero-minimum-for-fade-times.patch Patch20: 0001-Fix-a-number-of-potential-zero-value-field-values.patch +# From Jiri Slaby via boo#1141444 Patch21: delete_the_allocated_memory_in_respective_destructors.patch +#PATCH-FIX-GIT from areading's pull, will maybe fix bugs +Patch22: 0001-Introduce-limit-for-number-of-tag-client-processes.patch +#PATCH-FIX-GIT cures issue#6372 +Patch23: 0001-Fix-crash-in-messagereply-6372.patch BuildRequires: cmake BuildRequires: fdupes BuildRequires: freeglut-devel ++++++ 0001-Fix-crash-in-messagereply-6372.patch ++++++ >From 5bb35bf08a6189db3cc8456f377768a07313cdcb Mon Sep 17 00:00:00 2001 From: Jonas Kvinge <[email protected]> Date: Sat, 20 Jul 2019 19:52:37 +0200 Subject: [PATCH] Fix crash in messagereply (#6372) * Fix crash in messagereply * Fix formatting --- ext/libclementine-common/core/messagereply.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/libclementine-common/core/messagereply.h b/ext/libclementine-common/core/messagereply.h index 72904e765..764b5ce18 100644 --- a/ext/libclementine-common/core/messagereply.h +++ b/ext/libclementine-common/core/messagereply.h @@ -86,9 +86,9 @@ void MessageReply<MessageType>::SetReply(const MessageType& message) { finished_ = true; success_ = true; - emit Finished(success_); qLog(Debug) << "Releasing ID" << id() << "(finished)"; semaphore_.release(); + emit Finished(success_); } #endif // MESSAGEREPLY_H -- 2.16.4 ++++++ 0001-Introduce-limit-for-number-of-tag-client-processes.patch ++++++ >From c76697b42c30d50f87efc4b0beeca5a2e89795f3 Mon Sep 17 00:00:00 2001 From: Andrew Reading <[email protected]> Date: Thu, 28 Mar 2019 09:37:54 -0700 Subject: [PATCH] Introduce limit for number of tag client processes. Previously, the number of processes spawned was always QThread::idealThreadCount() (returning the number of logical CPU cores). On new systems with many cores, however, this can result in 12, 16, 24, or ... processes being spawned, which is a bit excessive. This establishes a new config variable, 'max_numprocs_tagclients' within the Settings group, in order to limit the maximum number of tag client processes that get spawned. It also adds a means of setting this via the Behavior page in Settings. It can be set to any integer in the interval [1, QThread::idealThreadCount()]; it defaults to the maximal value so as to emulate the old behavior. --- src/core/tagreaderclient.cpp | 9 ++++++++- src/ui/behavioursettingspage.cpp | 20 +++++++++++++++++++ src/ui/behavioursettingspage.h | 1 + src/ui/behavioursettingspage.ui | 42 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 71 insertions(+), 1 deletion(-) diff --git a/src/core/tagreaderclient.cpp b/src/core/tagreaderclient.cpp index 96434be52..853c2733e 100644 --- a/src/core/tagreaderclient.cpp +++ b/src/core/tagreaderclient.cpp @@ -18,6 +18,7 @@ along with Clementine. If not, see <http://www.gnu.org/licenses/>. */ +#include "player.h" #include "tagreaderclient.h" #include <QCoreApplication> @@ -34,8 +35,14 @@ TagReaderClient::TagReaderClient(QObject* parent) : QObject(parent), worker_pool_(new WorkerPool<HandlerType>(this)) { sInstance = this; + QSettings s; + s.beginGroup(Player::kSettingsGroup); + + int max_workers = QThread::idealThreadCount(); + int num_workers = s.value("max_numprocs_tagclients", max_workers).toInt(); + worker_pool_->SetExecutableName(kWorkerExecutableName); - worker_pool_->SetWorkerCount(QThread::idealThreadCount()); + worker_pool_->SetWorkerCount(num_workers); connect(worker_pool_, SIGNAL(WorkerFailedToStart()), SLOT(WorkerFailedToStart())); } diff --git a/src/ui/behavioursettingspage.cpp b/src/ui/behavioursettingspage.cpp index 62287b69d..b32816891 100644 --- a/src/ui/behavioursettingspage.cpp +++ b/src/ui/behavioursettingspage.cpp @@ -40,6 +40,15 @@ BehaviourSettingsPage::BehaviourSettingsPage(SettingsDialog* dialog) connect(ui_->b_show_tray_icon_, SIGNAL(toggled(bool)), SLOT(ShowTrayIconToggled(bool))); + connect(ui_->max_numprocs_tagclients, SIGNAL(valueChanged(int)), + SLOT(MaxNumProcsTagClientsChanged(int))); + ui_->max_numprocs_tagclients_value_label->setMinimumWidth( + QFontMetrics(ui_->max_numprocs_tagclients_value_label->font()) + .width("WWW")); + + // Limit max tag clients to number of CPU cores. + ui_->max_numprocs_tagclients->setMaximum(QThread::idealThreadCount()); + ui_->doubleclick_addmode->setItemData(0, MainWindow::AddBehaviour_Append); ui_->doubleclick_addmode->setItemData(1, MainWindow::AddBehaviour_Load); ui_->doubleclick_addmode->setItemData(2, MainWindow::AddBehaviour_OpenInNew); @@ -171,6 +180,12 @@ void BehaviourSettingsPage::Load() { .toInt())); ui_->seek_step_sec->setValue(s.value("seek_step_sec", 10).toInt()); + int max_numprocs_tagclients = + s.value("max_numprocs_tagclients", QThread::idealThreadCount()).toInt(); + ui_->max_numprocs_tagclients->setValue(max_numprocs_tagclients); + ui_->max_numprocs_tagclients_value_label->setText( + QString::number(max_numprocs_tagclients)); + if (s.value("play_count_short_duration", false).toBool()) { ui_->b_play_count_short_duration->setChecked(true); ui_->b_play_count_normal_duration->setChecked(false); @@ -283,6 +298,7 @@ void BehaviourSettingsPage::Save() { ui_->stop_play_if_fail_->isChecked()); s.setValue("menu_previousmode", menu_previousmode); s.setValue("seek_step_sec", ui_->seek_step_sec->value()); + s.setValue("max_numprocs_tagclients", ui_->max_numprocs_tagclients->value()); if (ui_->b_play_count_short_duration->isChecked()) { s.setValue("play_count_short_duration", true); @@ -321,3 +337,7 @@ void BehaviourSettingsPage::ShowTrayIconToggled(bool on) { ui_->b_keep_running_->setChecked(on); ui_->b_scroll_tray_icon_->setEnabled(on); } + +void BehaviourSettingsPage::MaxNumProcsTagClientsChanged(int value) { + ui_->max_numprocs_tagclients_value_label->setText(QString::number(value)); +} diff --git a/src/ui/behavioursettingspage.h b/src/ui/behavioursettingspage.h index 9f73c0f77..36be11880 100644 --- a/src/ui/behavioursettingspage.h +++ b/src/ui/behavioursettingspage.h @@ -36,6 +36,7 @@ class BehaviourSettingsPage : public SettingsPage { private slots: void ShowTrayIconToggled(bool on); + void MaxNumProcsTagClientsChanged(int value); private: Ui_BehaviourSettingsPage* ui_; diff --git a/src/ui/behavioursettingspage.ui b/src/ui/behavioursettingspage.ui index 2005d707c..88567d8dd 100644 --- a/src/ui/behavioursettingspage.ui +++ b/src/ui/behavioursettingspage.ui @@ -339,6 +339,48 @@ </layout> </widget> </item> + <item> + <widget class="QGroupBox" name="groupBox_max_tagclients"> + <property name="title"> + <string>Maximum number of child processes for tag handling (requires restart)</string> + </property> + <layout class="QHBoxLayout" name="horizontalLayout_8"> + <item> + <widget class="QLabel" name="numprocs_tagclients_label"> + <property name="text"> + <string>Number of processes:</string> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="max_numprocs_tagclients_value_label"> + <property name="text"> + <string/> + </property> + </widget> + </item> + <item> + <widget class="QSlider" name="max_numprocs_tagclients"> + <property name="minimum"> + <number>1</number> + </property> + <property name="maximum"> + <number>32</number> + </property> + <property name="value"> + <number>4</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="tickInterval"> + <number>1</number> + </property> + </widget> + </item> + </layout> + </widget> + </item> <item> <widget class="QGroupBox" name="groupBox_9"> <property name="title"> -- 2.16.4 ++++++ delete_the_allocated_memory_in_respective_destructors.patch ++++++ ++++ 1465 lines (skipped) ++++ between /work/SRC/openSUSE:Factory/clementine/delete_the_allocated_memory_in_respective_destructors.patch ++++ and /work/SRC/openSUSE:Factory/.clementine.new.4126/delete_the_allocated_memory_in_respective_destructors.patch
