title: Why sometimes I get an "Invalid transaction object" exception?
body: <p>Is there something wrong with this code?<br>
  Sometimes I get an unhandled "Invalid transaction object" exception in it:</p>
  
  <pre><code>procedure BlaBla;
  var
    TD: TDBXTransaction;
  begin
    TD := SQLConnection.BeginTransaction;
    try
      SQLConnection.ExecuteDirect('some sql command');
      SQLConnection.ExecuteDirect('some sql command');
      SQLConnection.CommitFreeAndNil(TD);
    except
      SQLConnection.RollbackFreeAndNil(TD);
    end;
  end;
  </code></pre>
  
  <p>This exception is being raised to the user, so I assume it's raised by RollbackFreeAndNil, since all rest is inside a try..except.</p>
  
  <p>Should I wrap RollbackFreeAndNil with another try..except? What a mess.</p>
  
  <p>I'm using Delphi 2009, DBX with Firebird 2.1 and Devart's driver.</p>