Affects Version/s: None
Fix Version/s: None
Environment:Mac OS X Leopard
Number of attachments :
UNIXServer.for_fd doesn't work. Suppose that we have the following script which we run in MRI:
File.unlink('test.sock') rescue nil
socket = UNIXServer.new('test.sock')
puts "Fileno = #
In the resulting jirb console we type:
UNIXServer.for_fd(...number that the above script printed...)
jirb currently throws an exception.
The attached patch fixes this problem: UNIXServer will accept a native file descriptor as argument. However I'm not sure how to write a unit test for this.