mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-04-24 23:47:20 +00:00
fix error in extscript and extupgrade with invalid updates interval if X-AW-Interval=1
This commit is contained in:
parent
e71da9bdfb
commit
2dccc92933
@ -271,9 +271,11 @@ QVariantHash ExtScript::run()
|
||||
cmdList.append(m_executable);
|
||||
qCInfo(LOG_LIB) << "Run cmd" << cmdList.join(QChar(' '));
|
||||
process->start(cmdList.join(QChar(' ')));
|
||||
} else if (times >= interval()) {
|
||||
times = 0;
|
||||
}
|
||||
|
||||
// update value
|
||||
if (times >= interval())
|
||||
times = 0;
|
||||
times++;
|
||||
|
||||
return value;
|
||||
|
@ -149,9 +149,11 @@ QVariantHash ExtUpgrade::run()
|
||||
QString cmd = QString("sh -c \"%1\"").arg(m_executable);
|
||||
qCInfo(LOG_LIB) << "Run cmd" << cmd;
|
||||
process->start(cmd);
|
||||
} else if (times >= interval()) {
|
||||
times = 0;
|
||||
}
|
||||
|
||||
// update value
|
||||
if (times >= interval())
|
||||
times = 0;
|
||||
times++;
|
||||
|
||||
return value;
|
||||
|
Loading…
Reference in New Issue
Block a user