Skip to content

Commit

Permalink
added back lines of code lost in a previous change to close child con…
Browse files Browse the repository at this point in the history
…nection when done

git-svn-id: svn+ssh://rubyforge.org/var/svn/spawn/spawn@15 2aabfe31-cc40-457c-aec7-21ad9ce7fb7d
  • Loading branch information
tra committed Apr 30, 2008
1 parent 367a500 commit 489a50b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/spawn.rb
Expand Up @@ -92,6 +92,8 @@ def fork_it(options)
logger.debug "spawn> child PID = #{Process.pid}"
yield
ensure
ActiveRecord::Base.connection.disconnect!
ActiveRecord::Base.remove_connection
end
logger.info "spawn> child[#{Process.pid}] took #{Time.now - start} sec"
# this form of exit doesn't call at_exit handlers
Expand Down

0 comments on commit 489a50b

Please sign in to comment.