Project

General

Profile

Actions

Bug #11260

closed

[PATCH] Net::FTP keeps a TCPServer opened when sending the data port fails

Bug #11260: [PATCH] Net::FTP keeps a TCPServer opened when sending the data port fails

Added by Eregon (Benoit Daloze) over 10 years ago. Updated over 10 years ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux]
[ruby-core:69577]

Description

Net::FTP will keep the TCPServer created in makeport opened if sendport fails.
The patch sends the port in its (only) caller instead, so the TCPServer is appropriately closed no matter the outcome.

This was detected with RubySpec and a leak checker based on test/lib/leakchecker.rb.


Files

Actions

Also available in: PDF Atom