mirror of
https://bitbucket.org/smil3y/kde-workspace.git
synced 2025-02-23 18:32:50 +00:00
kscreensaver: start counting from 1 when checking for free cookie
NOTE: 0 is considered as invalid reply by chromium Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
03854853a1
commit
37327385fa
1 changed files with 1 additions and 1 deletions
|
@ -235,7 +235,7 @@ void KScreenSaver::SimulateUserActivity()
|
||||||
uint KScreenSaver::Inhibit(const QString &application_name, const QString &reason_for_inhibit)
|
uint KScreenSaver::Inhibit(const QString &application_name, const QString &reason_for_inhibit)
|
||||||
{
|
{
|
||||||
// qDebug() << Q_FUNC_INFO << application_name << reason_for_inhibit;
|
// qDebug() << Q_FUNC_INFO << application_name << reason_for_inhibit;
|
||||||
uint cookiecounter = 0;
|
uint cookiecounter = 1;
|
||||||
while (m_cookies.contains(cookiecounter)) {
|
while (m_cookies.contains(cookiecounter)) {
|
||||||
if (cookiecounter >= INT_MAX) {
|
if (cookiecounter >= INT_MAX) {
|
||||||
kWarning() << "Inhibit limit reached";
|
kWarning() << "Inhibit limit reached";
|
||||||
|
|
Loading…
Add table
Reference in a new issue