Actions
Bug #82667
closedPassing a FAL file reference as data to the f:cObject view helper causes the creation of unwished fal-tempfiles in typo3temp/var/transient
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
File Abstraction Layer (FAL)
Target version:
-
Start date:
2017-10-04
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
We often do something like the following to generate images (image is a FAL object).
<f:cObject typoscriptObjectPath="lib.imageRenderer" data="{image}" />
We do this mainly to generate multiple versions with different resolutions, which then get chosen and loaded via javascript in the web browser.
But there is a problem:
- The CObjectViewHelper calls \TYPO3\CMS\Extbase\Reflection\ObjectAccess::getGettableProperties($data).
- The getGettableProperties method finds the \TYPO3\CMS\Core\Resource\FileReference::getForLocalProcessing method and calls it to get the property.
- getForLocalProcessing has the parameter "writable" which is true by default and thus causes the creation of a fal-tempfile in the typo3temp/var/transient directory.
Those fal-tempfiles are always unwished (at least in our case), because lib.imageRenderer is a IMAGE cObject and thus creates the temp files on its own.
I think it's generally a bad idea, to create a fal-tempfile, if someone passes a FileReference to the CObjectViewHelper.
This problem also exists in TYPO3 v7.
Actions