<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
By looking at the 1.3.15 code, I believe this bug still exists. If
connectivity is lost before jCIFS disconnects, then the
SmbTransport.doDisconnect() will be called over and over again.
Adding a try/catch block could stop that:<br>
<br>
<tt> protected void doDisconnect( boolean hard ) throws
IOException {<br>
ListIterator iter = sessions.listIterator();<br>
try {<br>
while (iter.hasNext()) {<br>
SmbSession ssn = (SmbSession)iter.next();<br>
ssn.logoff( hard );<br>
}<br>
socket.shutdownOutput();<br>
out.close();<br>
in.close();<br>
socket.close();<br>
} catch( IOException ioe ) {<br>
if (!hard)<br>
throw e;<br>
}<br>
digest = null;<br>
}</tt><br>
<br>
Thanks,<br>
Simon<br>
<br>
On 4/20/2011 12:11 PM, Simon wrote:
<blockquote cite="mid:4DAF0596.1040503@weatherill.org" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<font face="Helvetica, Arial, sans-serif">We're using jCIFS 1.3.13
and just encountered an endless loop that effectively took down
our application servers. The following appeared in our logs more
than 129 million times!<br>
<br>
</font><tt>2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3)
java.net.SocketException: Socket is closed<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
java.net.Socket.shutdownOutput(Socket.java:1407)<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
jcifs.smb.SmbTransport.doDisconnect(SmbTransport.java:358)<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
jcifs.util.transport.Transport.disconnect(Transport.java:210)<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
jcifs.util.transport.Transport.loop(Transport.java:122)<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
jcifs.util.transport.Transport.run(Transport.java:257)<br>
2011-04-14 18:24:07,766 ERROR [STDERR] (Transport3) at
java.lang.Thread.run(Thread.java:662)</tt><font face="Helvetica,
Arial, sans-serif"><br>
<br>
Can I get the source for 1.3.13 somewhere? I have 1.3.8 and the
latest (1.3.15), but can't find 1.3.13.<br>
<br>
My guess is that the exception is causing the connection to be
left in an open state only to attempt another disconnect (which
fails). Seeing the actual source may help finding out what is
going on.<br>
<br>
Thanks,<br>
Simon<br>
</font> </blockquote>
</body>
</html>