On Wed, 5 Mar 2003 15:42:14 -0500, Wei Dai wrote:

Hi Dai

>On Mon, Mar 03, 2003 at 04:45:41PM +1100, Ron Savage wrote:
>>I'm calling valdata.Get() in a loop to encrypt a set of strings.
>>
>>How can I tell I've reached EOF?
>
>You're not really giving us enough information to help you out. What
>is
>valdata? If it's a FileStore, maybe you need to use the
>AnyRetrievable()
>function? If you need more help, please post a minimal program with 
a
>main() function, that reproduces the problem, and a more detail
>description of what you're trying to do.

Good point. My apologies. I assumed you'd automatically recognize 
that line of your own code!

Here's what I ended up doing:

FileSource message_file("plain-message.dat", true, new HexDecoder);

SecByteBlock plain(cg.BlockSize()), cipher(cg.BlockSize()), 
out(cg.BlockSize());

while (message_file.MaxRetrievable() > 0)
{
...
}

However, I will look into AnyRetrievable. Thanx.
-- 
Ron Savage, [EMAIL PROTECTED] on 06/03/2003
Deakin University, 221 Burwood Highway, Burwood, VIC 3125, Australia
Phone: +61-3-9251 7067, Fax: +61-3-9251 7604
http://www.deakin.edu.au/~rons


Reply via email to