Until now, commit() with the "flush" flag would just commit the
transaction, no questions ask. Flushing however should only apply
to automatic transactions.
Change-Id: I621f145902cfdf201206b42c49c160aeeaf0e4ba
} elseif( $this->mTrxAutomatic ) {
wfWarn( "$fname: Explicit commit of implicit transaction. Something may be out of sync!" );
}
+ } else {
+ if ( !$this->mTrxLevel ) {
+ return; // nothing to do
+ } elseif( !$this->mTrxAutomatic ) {
+ wfWarn( "$fname: Flushing an explicit transaction, getting out of sync!" );
+ }
}
$this->doCommit( $fname );