public void Aborted(Exception e)
{
TransactionsEtwProvider etwLog = TransactionsEtwProvider.Log;
if (etwLog.IsEnabled())
{
etwLog.MethodEnter(TraceSourceType.TraceSourceLtm, this);
etwLog.EnlistmentAborted(_internalEnlistment);
}
lock (_internalEnlistment.SyncRoot)
{
_internalEnlistment.State.Aborted(_internalEnlistment, e);
}
if (etwLog.IsEnabled())
{
etwLog.MethodExit(TraceSourceType.TraceSourceLtm, this);
}
}
public void Rollback(SinglePhaseEnlistment en) { if (en == null) { throw new ArgumentNullException("en"); } try { this.handle.WaitOne(); } catch (ObjectDisposedException) { } lock (this.syncRoot) { if (this.transaction != null) { this.transaction.Dispose(); } if ((this.connection != null) && (this.connection.State != ConnectionState.Closed)) { this.connection.Close(); this.connection = null; } en.Aborted(); } }