# File lib/net/ssh/connection/channel.rb, line 67 def self.open( connection, log, buffers, type, data=nil ) channel = new( connection, log, buffers, type ) msg = buffers.writer msg.write_byte CHANNEL_OPEN msg.write_string type msg.write_long channel.local_id msg.write_long channel.local_window_size msg.write_long channel.local_maximum_packet_size msg.write data.to_s if data connection.send_message msg channel end