You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by "Daniel F. Savarese" <df...@savarese.org> on 2006/03/14 19:02:50 UTC

Re: [Net]: FTPClient.abort problem

In message <78...@mtlex02.NEXXLINK.INT>, "Gh
islain Gadbois" writes:
>I'm trying to abort an FTP transfer in a separate thread.
...
>Is there something that I'm doing wrong?

Off the top of my head, I don't think you're doing anything wrong.
The server replied with a 426, so it should have closed the data
connection, causing retrieveFile to terminate.

>What would be required to solve the problem?

If the action you plan to take after the abort is to quit, then you
can solve the problem by calling logout() right after abort().  The
server should definitely close the data connection in that case (but
who knows since it didn't do so for abort()).  Otherwise, use
retrieveFileStream and close the data connection from your end after
calling abort.

(BTW, thanks for providing the detailed sample program.)

daniel

-#-#-#-#-| Sleep and The Traveller |-#-#-#-#-#-#-#- http://www.savarese.org/
In distant lands, I hear the call of my home.     #     s a v a r e s e
Yet my work is not done.  My journey's just begun.-    software research
 -- http://www.sleepandthetraveller.com/          # http://www.savarese.com/


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org