Log.d(K9.LOG_TAG,"CoreService ("+getClass().getName()+") queueing Runnable "+runner.hashCode()+" with startId "+startId);
RunnablemyRunner=newRunnable()
{
publicvoidrun()
@@ -105,13 +118,13 @@ public abstract class CoreService extends Service
{
if(K9.DEBUG)
Log.d(K9.LOG_TAG,"CoreService ("+getClass().getName()+") running Runnable "+runner.hashCode()+" with startId "+startId);
Log.d(K9.LOG_TAG,"CoreService ("+className+") running Runnable "+runner.hashCode()+" with startId "+startId);
runner.run();
}
finally
{
if(K9.DEBUG)
Log.d(K9.LOG_TAG,"CoreService ("+getClass().getName()+") completed Runnable "+runner.hashCode()+" with startId "+startId);
Log.d(K9.LOG_TAG,"CoreService ("+className+") completed Runnable "+runner.hashCode()+" with startId "+startId);
wakeLock.release();
if(startId!=null)
{
@@ -121,9 +134,21 @@ public abstract class CoreService extends Service
}
};
if(threadPool==null)
{
Log.e(K9.LOG_TAG,"CoreService.execute ("+className+") called with no threadPool available; running Runnable "+runner.hashCode()+" in calling thread",newThrowable());
synchronized(this)
{
myRunner.run();
}
}
else
{
if(K9.DEBUG)
Log.d(K9.LOG_TAG,"CoreService ("+className+") queueing Runnable "+runner.hashCode()+" with startId "+startId);