Bug: Transaction is Committed instead of Rollback'ed

Dave Peticolas dave@krondo.com
Wed, 14 Mar 2001 14:23:32 -0800


Derek Atkins writes:
> Actually, I think I did just figure out the "right" way of doing this.
> Split out the force-change code into a second function,
> xaccTransDoRollback().  Then have xaccTransRollback() see if the
> backend has a rollback function; if so, just call that; if not, just
> call xaccTransDoRollback().  Then the backend can disable itself and
> then call the DoRollback() function to modify the engine without
> causing undue commit_edit calls.

Or put the backend detection in xaccTransRollback and then the backend
can choose to use xaccTransDoRollback without disabling itself?


> This does put the onus of correcting the engine transaction on the
> backend, but I think that's fine.  Currently none of the backends
> (except mine) even support the rollback method.

> Dave, would you like to work on this or would you like me to do it and
> just submit patches along with everything else?

Go ahead and submit it with a patch. Please put xaccTransDoRollback in
the TransactionP.h header.

dave