19684[BUGFIX] Files with unclean path indexed multiple times
Commit message
Review
-
Code review CR +2
- Wouter Wolters +2
-
Verified V +2
- Wouter Wolters +2
Files 4
Review log 54
Show 29 earlier messages
-
Stefan Neufeind uploaded patch set 2 05/27/13, 17:19
-
Stefan Neufeind commented on patch set 2 05/27/13, 17:19
Files with unclean identifier also lead to files being indexed multiple times. So this patch-set aims for generic "cleanup" for both cases, emulating what realpath() does (but without checking if a file exists). @Steffen: Please see if you're fine with this patch. Otherwise please apologize and let's talk :-) -
Stefan Neufeind commented on patch set 2 05/27/13, 17:19
for testing the case with an unclean identifier (wherever they might come from) with a file under fileadmin/ try: page.10 = IMAGE page.10.file = 1:./abc/../something.jpg -
Stefan Neufeind uploaded patch set 3 05/27/13, 17:19
-
Stefan Neufeind uploaded patch set 4 05/27/13, 17:19
-
Stefan Neufeind commented on patch set 4 05/27/13, 17:19
(1 inline comment) -
Dmitry Dulepov commented on patch set 5 05/27/13, 17:19
While don't you use realpath()? -
Stefan Neufeind commented on patch set 5 05/27/13, 17:19
It also checks for the existence of a file. We just want to clean up (relative) paths here. That's why it "almost" works like realpath in this regard. -
Stefan Neufeind uploaded patch set 5 05/27/13, 17:19
-
Stefan Neufeind commented on patch set 5 05/27/13, 17:19
(1 inline comment) CGL: added two more spaces :-) -
Alexander Opitz commented on patch set 1 05/27/13, 17:19
I would prefer that you didn't submit thisResourceStorage.php:30You know ... you should change all occurences of TYPO3\CMS\Core\Utility\GeneralUtility ;-) -
Alexander Opitz commented on patch set 5 05/27/13, 17:19
(1 inline comment) -
Stefan Neufeind uploaded patch set 7 05/27/13, 17:19
-
Stefan Neufeind commented on patch set 7 05/27/13, 17:19
Added testcases After working on the tests: Could it be that we (no longer?) need the separate cleanDirectoryNameAndFile() to clean a dirname with a file? Or which cases exist where that is still needed? -
Stefan Neufeind commented on patch set 7 05/27/13, 17:19
Somebody please have a look. Imho we're quite close to a good solution with this? :-) -
Alexander Opitz uploaded patch set 6 05/27/13, 17:19
-
Alexander Opitz commented on patch set 6 05/27/13, 17:19
Verified; Looks good to me, but someone else must approve -
Steffen Ritter commented on patch set 2 05/27/13, 17:19
I would prefer that you didn't submit this if we introduce a new function, please put it as static function to PathUtility so we do not need to instanciate an class. -
Philipp Gampe commented on patch set 1 05/27/13, 17:19
Looks good to me, but someone else must approve -
Philipp Gampe commented on patch set 7 05/27/13, 17:19
(4 inline comments) I do not think we are fully there yet, but looks good already -
Peter Niederlag commented on patch set 8 2 comments 05/27/13, 17:19
I would prefer that you didn't submit this tests would like some polish -
Philipp Gampe commented on patch set 8 1 comment 05/27/13, 17:19
Verified; Looks good to me, but someone else must approve Some more unit tests (also includes existing tests again). This patchset also takes care to preserve the slash at the beginning. The needs some testing with windows paths. -
Philipp Gampe commented on patch set 8 2 comments 05/27/13, 17:19
Fails -
Philipp Gampe uploaded patch set 8 05/27/13, 17:19
-
Philipp Gampe uploaded patch set 9 05/27/13, 17:19
-
Philipp Gampe commented on patch set 9 05/27/13, 17:19
fixed the comments -
Philipp Gampe commented on patch set 9 05/27/13, 17:19
Looks good to me, but someone else must approve I would still like to see a test on windows or with windows paths -
Anja Leichsenring commented on patch set 1 05/27/13, 17:19
(1 inline comment)ResourceStorage.php:30Reply... except for the ones in doc comments. IDEs do not handle this well. -
Mr. Jenkins commented on patch set 1 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8262/ : SUCCESS
-
Mr. Jenkins commented on patch set 2 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8305/ : SUCCESS -
Mr. Jenkins commented on patch set 3 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8466/ : SUCCESS -
Mr. Jenkins commented on patch set 4 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8467/ : SUCCESS -
Mr. Jenkins commented on patch set 5 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8468/ : SUCCESS -
Mr. Jenkins commented on patch set 6 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8697/ : SUCCESS -
Mr. Jenkins commented on patch set 7 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8700/ : SUCCESS -
Mr. Jenkins commented on patch set 8 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8801/ : SUCCESS -
Mr. Jenkins commented on patch set 9 05/27/13, 17:19
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/8832/ : SUCCESS -
Wouter Wolters commented on patch set 1 05/27/13, 17:19
Verified; Looks good to me, but someone else must approve -
Steffen Ritter commented on patch set 9 V -1 CR -1 07/04/13, 17:48
The path-cleanup is just wrong :) -
Steffen Ritter uploaded patch set 10 07/04/13, 18:22
-
Mr. Jenkins commented on patch set 10 07/04/13, 18:23
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/9365/ : SUCCESS -
Jigal van Hemert commented on patch set 10 V +1 CR +1 07/06/13, 21:07
Tested on Windows. Unit test for path test are green. -
Stefan Neufeind commented on patch set 10 CR +1 07/06/13, 21:14
BasicFileUtility.php:449for backport to 6.0 leave out this deprecated-annotationBasicFileUtility.php:449for backport to 6.0 leave out this deprecated-annotation -
Alexander Opitz commented on patch set 10 CR +1 07/06/13, 21:18
ResourceStorage.php:413GeneralUtility added in the use, so replace it in the complete file. -
Wouter Wolters commented on patch set 10 07/06/13, 21:27
ResourceStorage.php:154$basicFileUtility does not belong there.PathUtility.php:197remove empty line -
Wouter Wolters uploaded patch set 11 07/06/13, 21:30
-
Mr. Jenkins commented on patch set 11 07/06/13, 21:31
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/9505/ : SUCCESS -
Wouter Wolters commented on patch set 11 V +2 CR +2 07/06/13, 21:32
No functional changes, only a minor CGL cleanup which I discussed with Steffen Ritter. -
Wouter Wolters merged patch set 12 07/06/13, 21:32
-
Wouter Wolters commented on patch set 12 07/06/13, 21:32
Cherry Picked This patchset was cherry picked to change: I324c4637621165a56470fb95864eeff1254f62dc -
Andreas Wolf commented on patch set 12 07/06/13, 21:38
I think this change should not have been merged because all drivers that use non-hierarchical identifiers might be more broken now. I did not carefully review the changes, but tampering with the identifier on a storage-level seems to be error-prone. If at all, this should be done on the driver level. There we clearly need such a feature for e.g. the local storage (and WebDAV, Amazon S3...) -
Steffen Ritter commented on patch set 12 07/06/13, 21:40
non hierarchichal storages don't use pathes - and the problem is not in driver-level; driver already handles that correctly - aka it does not care! Indexing/Storage cannot handle that! Therefore we definetely need that at that point... -
Wouter Wolters commented on patch set 12 07/06/13, 22:43
Reverted This patchset was reverted in change: I7135b9478e01a5f95ad20df3a6b24bb5d9715ec8 -
Wouter Wolters commented on patch set 12 07/06/13, 22:44
Reverted because it broke several tests: There were 2 errors: 1) TYPO3\CMS\Core\Tests\Unit\Resource\ResourceStorageTest::addFileCallsDriverWithCorrectArguments InvalidArgumentException: File "vfs:/base-51d8985331d94/mount-51d8985331ce2/file.ext" does not exist. /var/www/websites/master/htdocs/typo3/sysext/core/Classes/Resource/ResourceStorage.php:722 /var/www/websites/master/htdocs/typo3/sysext/core/Tests/Unit/Resource/ResourceStorageTest.php:249 /var/www/websites/master/htdocs/typo3conf/ext/phpunit/Classes/TestRunner/ManualCliTestRunner.php:45 /var/www/websites/master/htdocs/typo3conf/ext/phpunit/Classes/TestRunner/ManualCliTestRunner.php:51 /var/www/websites/master/htdocs/typo3/cli_dispatch.phpsh:65 2) TYPO3\CMS\Core\Tests\Unit\Resource\ResourceStorageTest::addFileChangesFilenameIfFileExists InvalidArgumentException: File "vfs:/base-51d898533c069/mount-51d898533bfba/file.ext" does not exist. /var/www/websites/master/htdocs/typo3/sysext/core/Classes/Resource/ResourceStorage.php:722 /var/www/websites/master/htdocs/typo3/sysext/core/Tests/Unit/Resource/ResourceStorageTest.php:271 /var/www/websites/master/htdocs/typo3conf/ext/phpunit/Classes/TestRunner/ManualCliTestRunner.php:45 /var/www/websites/master/htdocs/typo3conf/ext/phpunit/Classes/TestRunner/ManualCliTestRunner.php:51 /var/www/websites/master/htdocs/typo3/cli_dispatch.phpsh:65 FAILURES!