Bug #64661
Bug #40005: Several unit tests fail under Windows system
DateValidator fails to validate incorrect dates
Status: | Resolved | Start date: | 2015-01-30 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | Nicole Cordes | % Done: | 100% |
|
Category: | FormEngine aka TCEforms | Spent time: | - | |
Target version: | 7.1 (Cleanup) | |||
TYPO3 Version: | 6.2 | Is Regression: | No | |
PHP Version: | Sprint Focus: | On Location Sprint | ||
Complexity: |
Description
If the function strptime is not included in PHP (mostly only on Windows systems) the DateValidator fails to detect invalid dates.
Associated revisions
[BUGFIX] DateValidator fails to validate incorrect dates
If the function "strptime" is not present in the environment (mostly on
Windows systems) the fallback to check a given date in the dateValidator
fails to detect invalid dates. The conversion from the given string to
a date object respects invalid dates and just converts them to valid
ones (by moving in next month/year). Therefore the function returns an
object instead of false. This patch adds a value comparison between old
and new value to be sure still the same date string is returned.
Releases: master, 6.2
Resolves: #64661
Change-Id: I739d309278143bb5fc24c48ca7bb884a1e25a442
Reviewed-on: http://review.typo3.org/36467
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Tested-by: Oliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: Steffen Müller <typo3@t3node.com>
Tested-by: Steffen Müller <typo3@t3node.com>
[BUGFIX] DateValidator fails to validate incorrect dates
If the function "strptime" is not present in the environment (mostly on
Windows systems) the fallback to check a given date in the dateValidator
fails to detect invalid dates. The conversion from the given string to
a date object respects invalid dates and just converts them to valid
ones (by moving in next month/year). Therefore the function returns an
object instead of false. This patch adds a value comparison between old
and new value to be sure still the same date string is returned.
Releases: master, 6.2
Resolves: #64661
Change-Id: I739d309278143bb5fc24c48ca7bb884a1e25a442
Reviewed-on: http://review.typo3.org/36469
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: Steffen Müller <typo3@t3node.com>
Tested-by: Steffen Müller <typo3@t3node.com>
History
#1 Updated by Gerrit Code Review 6 months ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36467
#2 Updated by Gerrit Code Review 6 months ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36467
#3 Updated by Gerrit Code Review 6 months ago
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36469
#4 Updated by Nicole Cordes 6 months ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 091658d36c025bb48012c1b53d1a5c824819517b.