From kde-panel-devel Wed Apr 29 13:24:53 2015 From: "Emmanuel Pescosta" Date: Wed, 29 Apr 2015 13:24:53 +0000 To: kde-panel-devel Subject: Re: Review Request 123555: Fix a crash in PowermanagementEngine::populateApplicationData when the gi Message-Id: <20150429132453.21733.97673 () mimi ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-panel-devel&m=143031390813165 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============1474083824097772904==" --===============1474083824097772904== Content-Type: multipart/alternative; boundary="===============4755282867318840249==" --===============4755282867318840249== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/123555/ ----------------------------------------------------------- (Updated April 29, 2015, 1:24 p.m.) Status ------ This change has been marked as submitted. Review request for Plasma and Kai Uwe Broulik. Changes ------- Submitted with commit 08cbba07eb8927ce3a0f864eda8dfe1f8f1a6e44 by Emmanuel Pescosta to branch Plasma/5.3. Repository: plasma-workspace Description ------- Fix a crash in PowermanagementEngine::populateApplicationData when the given name is empty. Use QString::section instead of QString::split + QList::last (which requires a non empty list) to prevent the crash. The crash is sometimes reproducible with Spotify. (plasmashell crashes in an endless loop in this case) IMO: Maybe the PowermanagementEngine should only add inhibitions from applications which have a non empty name?! Diffs ----- dataengines/powermanagement/powermanagementengine.cpp 2fbf23f Diff: https://git.reviewboard.kde.org/r/123555/diff/ Testing ------- Thanks, Emmanuel Pescosta --===============4755282867318840249== MIME-Version: 1.0 Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: 7bit
This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/123555/

This change has been marked as submitted.


Review request for Plasma and Kai Uwe Broulik.
By Emmanuel Pescosta.

Updated April 29, 2015, 1:24 p.m.

Changes

Submitted with commit 08cbba07eb8927ce3a0f864eda8dfe1f8f1a6e44 by Emmanuel Pescosta to branch Plasma/5.3.
Repository: plasma-workspace

Description

Fix a crash in PowermanagementEngine::populateApplicationData when the given name is empty.

Use QString::section instead of QString::split + QList::last (which requires a non empty list) to prevent the crash.

The crash is sometimes reproducible with Spotify. (plasmashell crashes in an endless loop in this case)

IMO: Maybe the PowermanagementEngine should only add inhibitions from applications which have a non empty name?!

Diffs

  • dataengines/powermanagement/powermanagementengine.cpp (2fbf23f)

View Diff

--===============4755282867318840249==-- --===============1474083824097772904== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KUGxhc21hLWRl dmVsIG1haWxpbmcgbGlzdApQbGFzbWEtZGV2ZWxAa2RlLm9yZwpodHRwczovL21haWwua2RlLm9y Zy9tYWlsbWFuL2xpc3RpbmZvL3BsYXNtYS1kZXZlbAo= --===============1474083824097772904==--