Merge pull request #814 from c-wind/master

add txn.Rollback on txn error
This commit is contained in:
qiuyesuifeng
2015-12-31 12:39:24 +08:00

View File

@ -38,6 +38,7 @@ func RunInNewTxn(store Storage, retryable bool, f func(txn Transaction) error) e
continue
}
if err != nil {
txn.Rollback()
return errors.Trace(err)
}