jglobus / JGlobus

jGlobus is a collection of Java client libraries for Globus® Toolkit security, GRAM, and GridFTP.
http://www.globus.org/toolkit/jglobus/
Apache License 2.0
24 stars 44 forks source link

fix: close the inner stream even if an exception occured. #153

Closed romainreuillon closed 9 years ago

romainreuillon commented 9 years ago

same kind of error here:

FINE: Socket closed
java.net.SocketException: Socket closed
        at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:116)
        at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
        at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
        at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
        at org.globus.ftp.extended.GridFTPOutputStream.writeToken(GridFTPOutputStream.java:60)
        at org.globus.ftp.extended.GridFTPOutputStream.flush(GridFTPOutputStream.java:43)
        at org.globus.gsi.gssapi.net.GssOutputStream.flushData(GssOutputStream.java:114)
        at org.globus.gsi.gssapi.net.GssOutputStream.close(GssOutputStream.java:121)
        at org.globus.ftp.vanilla.FTPControlChannel.close(FTPControlChannel.java:247)
        at org.globus.ftp.FTPClient.close(FTPClient.java:958)
        at org.globus.ftp.FTPClient.close(FTPClient.java:930)
        at org.globus.io.streams.GridFTPOutputStream.<init>(GridFTPOutputStream.java:115)
        at org.globus.io.streams.GridFTPOutputStream.<init>(GridFTPOutputStream.java:79)
        at org.globus.io.streams.GridFTPOutputStream.<init>(GridFTPOutputStream.java:37)