[jcifs] Exception after ten minutes pooling the shared directory

Michael B Allen mba2000 at ioplex.com
Wed Sep 21 04:12:23 GMT 2005


On Tue, 20 Sep 2005 12:08:47 -0400
Michael B Allen <mba2000 at ioplex.com> wrote:

> On Tue, 20 Sep 2005 12:27:15 +0200
> Erdei Bela <ebela at freemail.hu> wrote:
> 
> > Hello!
> > 
> > 
> > I wrote a simple test program which just keeps polling a directory in an 
> > infinite loop.
> > After ten minutes of running it constantly throws an exception, and 
> > after that the directory cannot be read again, only after restart.
> > The watched server is a linux and running samba-3.0.14a-Debian and test 
> > program is running on windows XP.
> 
> I was able to reproduce this. Nice detective work. Apparently something's
> timeing out after almost exactly 10 minutes. I'm on the run right now
> though so I'll have to fix this later tonight or maybe tomarrow.

Well there's a whole slew of problems here. The source of the issue is
that after ~10 minutes a NetBIOS keep-alive message is being received
which is not being handled properly because of what is probably a
precision error in a conditional expression in doPeek(). But the code
that tries to recover from out-of-phase type situations should have
allowed the code to recover. Unfortunately that implementation is wrong
in two ways. Arrrg.

Anyway, rather than simply fix the keep-alive handling I need to work
through each issue backwards.

The good news is this is NOT a concurrency flaw as I previously
dreaded. It's a simple dumb programmer type error. So once this is
worked out and once I apply the other little issues (like the bogus
signing error) I will release 1.2.4.

Mike



More information about the jcifs mailing list