// Token: 0x0600407B RID: 16507 RVA: 0x000F03D4 File Offset: 0x000EE5D4
 protected override void Finalize()
 {
     try
     {
         if (this.m_faultExceptions != null && !this.m_isHandled && !Environment.HasShutdownStarted && !AppDomain.CurrentDomain.IsFinalizingForUnload() && !TaskExceptionHolder.s_domainUnloadStarted)
         {
             foreach (ExceptionDispatchInfo exceptionDispatchInfo in this.m_faultExceptions)
             {
                 Exception          sourceException = exceptionDispatchInfo.SourceException;
                 AggregateException ex = sourceException as AggregateException;
                 if (ex != null)
                 {
                     AggregateException ex2 = ex.Flatten();
                     using (IEnumerator <Exception> enumerator2 = ex2.InnerExceptions.GetEnumerator())
                     {
                         while (enumerator2.MoveNext())
                         {
                             Exception ex3 = enumerator2.Current;
                             if (ex3 is ThreadAbortException)
                             {
                                 return;
                             }
                         }
                         continue;
                     }
                 }
                 if (sourceException is ThreadAbortException)
                 {
                     return;
                 }
             }
             AggregateException ex4 = new AggregateException(Environment.GetResourceString("TaskExceptionHolder_UnhandledException"), this.m_faultExceptions);
             UnobservedTaskExceptionEventArgs unobservedTaskExceptionEventArgs = new UnobservedTaskExceptionEventArgs(ex4);
             TaskScheduler.PublishUnobservedTaskException(this.m_task, unobservedTaskExceptionEventArgs);
             if (TaskExceptionHolder.s_failFastOnUnobservedException && !unobservedTaskExceptionEventArgs.m_observed)
             {
                 throw ex4;
             }
         }
     }
     finally
     {
         base.Finalize();
     }
 }