[jcifs] bug accessing win2003 server dfs

aschlett at web.de aschlett at web.de
Fri Sep 1 07:27:02 GMT 2006


The missing trailing slash in the path after a dfs referral made me change SmbFile.java's getDfcUncPath0() to this:

    String getDfsUncPath0() throws SmbException {
        getUncPath0();
        if( dfsReferral == null ) {
            return null;
        }
        // BUGFIX: adding slash
        String dunc = dfsReferral.nodepath + unc.substring( dfsReferral.path.length() ) + "\\";
        //return "".equals( dunc ) ? "\\" : dunc;
        return dunc;
    }

I found this problem on the list, but it wasn't considered a major bug and no fix was provided. 
For me this fix works very well, don't know if it affects other though, just wanted to share it.
If it'S a real bug, it would be nice if a fix would be part of the next version...

Alex
______________________________________________________________________
XXL-Speicher, PC-Virenschutz, Spartarife & mehr: Nur im WEB.DE Club!		
Jetzt gratis testen! http://freemail.web.de/home/landingpad/?mc=021130



More information about the jcifs mailing list