[BUGFIX] FAL: Correctly iterate folder content with offset 75/52275/2
authorMarkus Klein <markus.klein@typo3.org>
Thu, 30 Mar 2017 22:06:58 +0000 (00:06 +0200)
committerJigal van Hemert <jigal.van.hemert@typo3.org>
Fri, 31 Mar 2017 10:18:31 +0000 (12:18 +0200)
commite9ba80c2fb92fd0fbda65d473d0e0347fd9154f8
tree29f2d68289b6a806538f262e2284a34829e091f7
parente8767787037d0ec25b65fb3ff5ec5a6c54b3a6b6
[BUGFIX] FAL: Correctly iterate folder content with offset

Whenever a list of files of a folder is queried with an offset
make sure we handle filtered files correctly by not taking them
into account when searching for the first eligible file for the
result.

A direct seek() to the start position is wrong as those first files
may contain files would be later on filtered.
The solution is to iterate the whole file list and only count
non-filtered elements to reach the correct starting point.

Releases: master, 7.6, 6.2
Resolves: #80589
Change-Id: I79a6d298599d31aa49c36fd51cc5bbe2cf2ccf3a
Reviewed-on: https://review.typo3.org/52275
Tested-by: TYPO3com <no-reply@typo3.com>
Tested-by: Riccardo De Contardi <erredeco@gmail.com>
Reviewed-by: Frans Saris <franssaris@gmail.com>
Tested-by: Frans Saris <franssaris@gmail.com>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
Tested-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
typo3/sysext/core/Classes/Resource/Driver/LocalDriver.php