mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
set encoding to binmode for pipe
This commit is contained in:
parent
486db21f91
commit
0e9144dcec
3 changed files with 6 additions and 0 deletions
|
@ -1380,6 +1380,8 @@ class BasicsTest < ActiveRecord::TestCase
|
|||
})
|
||||
|
||||
rd, wr = IO.pipe
|
||||
rd.binmode
|
||||
wr.binmode
|
||||
|
||||
ActiveRecord::Base.connection_handler.clear_all_connections!
|
||||
|
||||
|
|
|
@ -31,6 +31,8 @@ module ActiveRecord
|
|||
object_id = ActiveRecord::Base.connection.object_id
|
||||
|
||||
rd, wr = IO.pipe
|
||||
rd.binmode
|
||||
wr.binmode
|
||||
|
||||
pid = fork {
|
||||
rd.close
|
||||
|
|
|
@ -37,6 +37,8 @@ module ActiveSupport
|
|||
module Forking
|
||||
def run_in_isolation(&blk)
|
||||
read, write = IO.pipe
|
||||
read.binmode
|
||||
write.binmode
|
||||
|
||||
pid = fork do
|
||||
read.close
|
||||
|
|
Loading…
Reference in a new issue