How to download file ftp server using FTPClient?
<p>I need to download files from ftp server using FTPClient - I make application for Android. I have following code:</p>

<pre><code>    File f=new File(Environment.getExternalStorageDirectory().getAbsoluteFile()+
            "/FTPDownloader/"+file.getName());
    f.createNewFile();
    BufferedOutputStream buffIn=new BufferedOutputStream(new FileOutputStream(f));
    InputStream stream=client.retrieveFileStream(file.getName());
    byte[] buffer = new byte[1024];
    int sz=0;
    if (stream==null) {

        Log.e("ok", "ok");
    }
</code></pre>

<p>"file" is FTPFile object. But I see "ok" in log always, therefore filestream is null. Where have I made mistake? Thank you. </p>
