Return-Path: Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: (qmail 35720 invoked from network); 11 Jul 2010 12:02:50 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 11 Jul 2010 12:02:50 -0000 Received: (qmail 73943 invoked by uid 500); 11 Jul 2010 12:02:50 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 73546 invoked by uid 500); 11 Jul 2010 12:02:48 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 73533 invoked by uid 99); 11 Jul 2010 12:02:48 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 Jul 2010 12:02:48 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 Jul 2010 12:02:45 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o6BBssQ1027860 for ; Sun, 11 Jul 2010 11:54:54 GMT Message-ID: <6357277.314661278849294678.JavaMail.jira@thor> Date: Sun, 11 Jul 2010 07:54:54 -0400 (EDT) From: "Sebb (JIRA)" To: issues@commons.apache.org Subject: [jira] Updated: (NET-270) Incorrect error handling in method initiateListParsing of FTPClient In-Reply-To: <268858841.1239201793722.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/NET-270?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Sebb updated NET-270: --------------------- Component/s: FTP > Incorrect error handling in method initiateListParsing of FTPClient > ------------------------------------------------------------------- > > Key: NET-270 > URL: https://issues.apache.org/jira/browse/NET-270 > Project: Commons Net > Issue Type: Bug > Components: FTP > Affects Versions: 2.0 > Environment: XP - java version "1.5.0_09" - FileZilla server 0.9.30beta > Reporter: Gilles Gaillard > Attachments: FTPClientUnitTest.java > > Original Estimate: 24h > Remaining Estimate: 24h > > In method initiateListParsing of FTPClient, errors when opening the data connection are not correctly handled. > This leads to ignore message delivered by the server and further operation with the FTPClient instance are not valid. > As an example, considere the attached unit test. When such an error is met, using the _sendNoOp_ command returns false. > Here is an output of the test: > {noformat} > F:\dev\jakarta\>run org.apache.commons.vfs.provider.ftp.FTPClientUnitTest 10.0.0.x 21 /GILLES/source usr pass 5500 > Ignoring error when creating client at iteration: 1152 > Error at iteration: 1155 > java.net.SocketTimeoutException: Accept timed out > at java.net.PlainSocketImpl.socketAccept(Native Method) > at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384) > at java.net.ServerSocket.implAccept(ServerSocket.java:450) > at java.net.ServerSocket.accept(ServerSocket.java:421) > at org.apache.commons.net.ftp.FTPClient._openDataConnection_(FTPClient.java:489) > at org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2296) > at org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2269) > at org.apache.commons.net.ftp.FTPClient.listFiles(FTPClient.java:2046) > at org.apache.commons.vfs.provider.ftp.FTPClientUnitTest.testConnectTimeoutInList(FTPClientUnitTest.java:70) > at org.apache.commons.vfs.provider.ftp.FTPClientUnitTest.main(FTPClientUnitTest.java:110) > Exception in thread "main" junit.framework.AssertionFailedError: NOOP failed at iteration 1155 > at junit.framework.Assert.fail(Assert.java:47) > at junit.framework.Assert.assertTrue(Assert.java:20) > at org.apache.commons.vfs.provider.ftp.FTPClientUnitTest.testConnectTimeoutInList(FTPClientUnitTest.java:75) > at org.apache.commons.vfs.provider.ftp.FTPClientUnitTest.main(FTPClientUnitTest.java:110) > {noformat} -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.