Tomasz Kojm wrote:
Works for me.On Tue, 30 Mar 2004 18:37:53 -0500 Joe Maimon <[EMAIL PROTECTED]> wrote:
Anyone care to try these? fresh from the oven. barely tested.
+ btread = ( (maxsize && ( size + btread > maxsize)) ?
(maxsize - size) : btread);
The patch is incorrect.
the call to read will never read more than StreamMaxLength and instead of returning with an error, we will scan whatever we have up to that point.
(if streammaxlength is greater than sizeof(buff))
Perhaps it should be written like this
if(maxsize && (size + btread > maxsize)) { /* next loop iteration might read too much data */
/* only read in at most up to maxsize */ btread = (maxsize - size); }
What am I missing?
------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click _______________________________________________ Clamav-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/clamav-users
