Method: ChildProcess::Windows::Lib.dont_inherit

Defined in:
lib/childprocess/windows/lib.rb

.dont_inherit(file) ⇒ Object



266
267
268
269
270
271
272
# File 'lib/childprocess/windows/lib.rb', line 266

def dont_inherit(file)
  unless file.respond_to?(:fileno)
    raise ArgumentError, "expected #{file.inspect} to respond to :fileno"
  end

  set_handle_inheritance(handle_for(file.fileno), false)
end