launch_daemon: Fixed Alexander's logic mixup.

* The warning in GCC 4 is just that, a warning. It doesn't mean
  the previous version was wrong :-)
This commit is contained in:
Axel Dörfler 2015-07-23 09:03:36 +02:00
parent 353af6bf04
commit 2fb7433b58

View File

@ -1011,9 +1011,9 @@ LaunchDaemon::_LaunchJobs(Target* target, bool forceNow)
void
LaunchDaemon::_LaunchJob(Job* job, bool forceNow)
{
if ((job == NULL || job->IsLaunched() || !forceNow)
if (job == NULL || job->IsLaunched() || (!forceNow
&& (!job->EventHasTriggered() || !job->CheckCondition(*this)
|| Events::TriggerDemand(job->Event()))) {
|| Events::TriggerDemand(job->Event())))) {
return;
}