提交 5b3f7563 编写于 作者: J Jeremy Kemper

Remove wasteful signal trap from transactions. Backport from 2-0-stable.

git-svn-id: http://svn-commit.rubyonrails.org/rails/branches/1-2-stable@8895 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
上级 f756bfbe
......@@ -82,7 +82,6 @@ def self.included(base)
# Tribute: Object-level transactions are implemented by Transaction::Simple by Austin Ziegler.
module ClassMethods
def transaction(*objects, &block)
previous_handler = trap('TERM') { raise TransactionError, "Transaction aborted" }
increment_open_transactions
begin
......@@ -101,7 +100,6 @@ def transaction(*objects, &block)
raise
ensure
decrement_open_transactions
trap('TERM', previous_handler)
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册