Fixed stream handling for too big files

This commit is contained in:
Marcin Kurczewski 2014-05-20 22:30:12 +02:00
parent 8e39f08cf5
commit 73a64034b0

View file

@ -41,8 +41,6 @@ class TransferHelper
fflush($dstHandle);
if ($maxBytes !== null and ftell($dstHandle) > $maxBytes)
{
fclose($srcHandle);
fclose($dstHandle);
throw new SimpleException(
'File is too big (maximum size: %s)',
TextHelper::useBytesUnits($maxBytes));