On Fri, Jun 18, 2010 at 3:49 PM, Mark Murphy <[email protected]> wrote:
> On Fri, Jun 18, 2010 at 4:41 PM, Robert Macaulay
> <[email protected]> wrote:
>> I actually need to submit you a bug on that. I had an underlocked
>> error thrown from the wakeful intent service in the finally block.
>> java.lang.RuntimeException: WakeLock under-locked
>> But looking at the WakefulIntentService, this shouldn't be able to
>> happen.
>
> I made a patch that addressed this issue a few weeks ago, when
> somebody brought it to my attention.
I reproduced it. Its not a thread death

The code looks like this(pseudo code)
try{
  print Runtime
  if(!valid)
    print NotValid;
    return;
  }
  print Valid Run
  Do stuff
}finally{
  print end
  schedule alarm
  print rescheduled for 120000
}

The last output was:
18:11:15 RunTime
18:11:15 Valid run
18:11:15 end
18:11:15 rescheduled for 120000

So the alarm is being set for 120000ms in the future and never running
again. Seems to be an AlarmManager bug. Going to be tricky to
reproduce it for a bug report. In the meantime, I'm thinking of
swapping to either a WAKEUP alarm, or a repeating one. WAKEUP will be
the most compatible change, but slightly less efficient.

It is definitely is related to device sleep related sleep though. Wish
there was more info I could gather.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to