[jcifs] bugreport - error caught

Dmitry surfer at ok.ru
Tue Jan 15 16:56:53 EST 2002


hello, Mike.
i've found problem:

it was due to getting listing of IPC$ device.
but then i do not know how to handle such error

try{
     
     System.out.println("trying to get 
:"+"smb://"+host+pwd);
     SmbFile f_=new SmbFile("smb://"+host+pwd);
     f_.listFiles();
     System.out.println("Switched correctly");
     }catch (Exception e){
         System.out.println("trying to get 
:"+"smb://"+host+pwd);
         SmbFile f_=new 
SmbFile("smb://"+host+replace0(replace0(java.net.URLEncoder.encode(pwd),"%2F","/"),"%5C","\\"));
     System.out.println("Switched correctly : 
"+f_.listFiles().length);
     }
     
     }
     catch (Exception e) {
         throw new FTPException(e.getMessage());
     }

in upper layers FTPException is intecepted and handled but
that code produces exception that came out of my code and 
i couldn't catch it :((( i've sent traceroute of that in 
previous bug report.

maybe i'm dummy but i do not see decision of problem
---
Professional hosting for everyone - http://www.host.ru




More information about the jcifs mailing list