Consider VTODOs in pre-check

This commit is contained in:
Thomas Bruederli 2014-03-18 12:08:54 +01:00
parent 36dda1afd4
commit 26824f3d51

View file

@ -129,7 +129,7 @@ class libvcalendar implements Iterator
try {
// estimate the memory usage and try to avoid fatal errors when allowed memory gets exhausted
if ($memcheck) {
$count = substr_count($vcal, 'BEGIN:VEVENT');
$count = substr_count($vcal, 'BEGIN:VEVENT') + substr_count($vcal, 'BEGIN:VTODO');
$expected_memory = $count * 70*1024; // assume ~ 70K per event (empirically determined)
if (!rcube_utils::mem_check($expected_memory)) {