From: nagachika00@... Date: 2015-08-12T16:40:33+00:00 Subject: [ruby-core:70354] [Ruby trunk - Bug #11260] [PATCH] Net::FTP keeps a TCPServer opened when sending the data port fails Issue #11260 has been updated by Tomoyuki Chikanaga. Backport changed from 2.0.0: WONTFIX, 2.1: REQUIRED, 2.2: REQUIRED to 2.0.0: WONTFIX, 2.1: REQUIRED, 2.2: DONE Backported into `ruby_2_2` branch at r51556. ---------------------------------------- Bug #11260: [PATCH] Net::FTP keeps a TCPServer opened when sending the data port fails https://bugs.ruby-lang.org/issues/11260#change-53770 * Author: Benoit Daloze * Status: Closed * Priority: Normal * Assignee: Benoit Daloze * ruby -v: ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux] * Backport: 2.0.0: WONTFIX, 2.1: REQUIRED, 2.2: DONE ---------------------------------------- `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-------------------------------- 0001-lib-net-ftp.rb-makeport-close-the-TCPServer.patch (3.43 KB) -- https://bugs.ruby-lang.org/