[Clamav-devel] libclamav/blob.c: call cli_scanbuff() in file…

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Anton Yuzhaninov
Date:  
To: clamav-devel
Subject: [Clamav-devel] libclamav/blob.c: call cli_scanbuff() in fileblobAddData()
Hello.

Why to fileblobAddData() was added to call to cli_scanbuff()?

It add considerable performance degradation, but as I can see it don't
affect finding viruses (please correct me if I'm wrong, and without
this code some viruses may be not detected).

To test was used may incoming mail (including spam) and several
messages with viruses.

With call to cli_scanbuff in fileblobAddData():

460.48 user 57.59 sys (518.07 total)

Without call to cli_scanbuff (MAX_SCAN_SIZE was undefined)
197.41 user 38.73 sys (236.14 total)

May be code added in revision 1948 was intended to be optimization,
but on real mail (where viruses uncommon) it makes clamav two times
slower.

-- 
WBR,
 Anton Yuzhaninov
 Rambler


_______________________________________________
http://lurker.clamav.net/list/clamav-devel.html
Please submit your patches to our Bugzilla: http://bugs.clamav.net