[jcifs] Null pointer exception in ServerMessageBlock.java

Jake Goulding goulding at vivisimo.com
Tue Jun 20 21:24:48 GMT 2006

Thanks for the tip...

I traced the null String back to line 828 of SmbFile.java:

send( new SmbComNTCreateAndX( unc, flags, access, shareAccess, attrs, 
options, null ), response );

unc is null here, so I added a call to getUncPath0() directly before the 
if statement. Tracing into the call to getUncPath0(), I see that the if( 
in[i] != '/' ) on line 986 is true, causing the function to return null. 
Looking at the url given, I see the path is "#@pdc/IPC$/lsarpc". The 
host, authority and protocol all seem to be fine.

Any thoughts?

Michael B Allen wrote:
> On Tue, 20 Jun 2006 15:09:13 -0400
> Jake Goulding <goulding at vivisimo.com> wrote:
>> At line 212 of ServerMessageBlock.java, I get a Null Pointer Exception, 
>> and I was hoping someone could help me figure it out.
> Looks like the path for the named pipe is null. Can't say for sure why
> that is since I don't really use the Lsarpc patch. Just trace up the
> call stack and println the path until you find where it's becoming null.
> Mike

Jake Goulding
Software Engineer
Vivísimo, Inc.

"One of the main causes of the fall of the Roman Empire was that,
lacking zero, they had no way to indicate successful termination
of their C programs."

More information about the jcifs mailing list