Esempio n. 1
0
        public void Run(Object o)
        {
            PooledTaskRunner p = o as PooledTaskRunner;

            p.runningThread = System.Threading.Thread.CurrentThread;
            try
            {
                p.RunTask();
            }
            finally
            {
                p.runningThread = null;
            }
        }
        public void Run(Object o)
        {
            PooledTaskRunner p = o as PooledTaskRunner;

            try
            {
                p.runningThread = System.Threading.Thread.CurrentThread;
                p.workExecutionContextCurrentlyProcessing.Value = true;
                p.RunTask();
            }
            finally
            {
                p.workExecutionContextCurrentlyProcessing.Value = false;
                p.runningThread = null;
            }
        }