[net-ftp]Received file is short...

View: New views
2 Messages — Rating Filter:   Alert me  

[net-ftp]Received file is short...

by Nation, Carey :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm using FTPClient to get a file from a server using receiveFile.  No
amount of closing the stream, flushing the stream, disconnecting the
server, or dancing a jig seems to make the entire file come down.  It's
about 40k short, which sure smells like a block short to me.  My finally
block looks like:

 

Finally

{

            Stream.close();

            Client.disconnect();

}

 

Sorry for the caps, Outlook is trying to "help."

 

The stream is a FileOutputStream.  What am I missing?

 

Thanks!

________________________________

Carey Nation <mailto:carey.nation@...>  

Lead Software Engineer

CNN BEST

Broadcast Production Systems

Video Solutions Group

(404)827-2935 (wk)

(404)824-0033 (cell)

________________________________

 


Re: [net-ftp]Received file is short...

by andrew ox. :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Could you provide a short program or fragment to demonstrate the problem.

Perhaps in a JUnit test?

2008/6/4 Nation, Carey <Carey.Nation@...>:

> I'm using FTPClient to get a file from a server using receiveFile.  No
> amount of closing the stream, flushing the stream, disconnecting the
> server, or dancing a jig seems to make the entire file come down.  It's
> about 40k short, which sure smells like a block short to me.  My finally
> block looks like:
>
>
>
> Finally
>
> {
>
>            Stream.close();
>
>            Client.disconnect();
>
> }
>
>
>
> Sorry for the caps, Outlook is trying to "help."
>
>
>
> The stream is a FileOutputStream.  What am I missing?
>
>
>
> Thanks!
>
> ________________________________
>
> Carey Nation <mailto:carey.nation@...>
>
> Lead Software Engineer
>
> CNN BEST
>
> Broadcast Production Systems
>
> Video Solutions Group
>
> (404)827-2935 (wk)
>
> (404)824-0033 (cell)
>
> ________________________________
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@...
For additional commands, e-mail: user-help@...

LightInTheBox - Buy quality products at wholesale price