[BUGFIX] Close file handle only if unused in FileWriter 04/57204/8
authorSusanne Moog <susanne.moog@typo3.org>
Tue, 12 Jun 2018 14:19:57 +0000 (16:19 +0200)
committerBenni Mack <benni@typo3.org>
Thu, 14 Jun 2018 04:31:00 +0000 (06:31 +0200)
commit233e876814cfc82e99dc2067c7a59a21e84eec9c
treef6cff6ebc6bbbf8970d1df829ff21e84b82980a4
parentc347ac7ac58758bf1739affdc345808074c43153
[BUGFIX] Close file handle only if unused in FileWriter

Keep track of open file handles for resources across instances and
close the handle only on destructing the last known instance using it.

Resolves: #85245
Releases: master
Change-Id: I896f630521136474f843a271b5bd7c752a2efdaf
Reviewed-on: https://review.typo3.org/57204
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
typo3/sysext/core/Classes/Log/Writer/FileWriter.php
typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php