Bug #64661

Bug #40005: Several unit tests fail under Windows system

DateValidator fails to validate incorrect dates

Added by Nicole Cordes over 5 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
FormEngine aka TCEforms
Target version:
Start date:
2015-01-30
Due date:
% Done:

100%

TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

If the function strptime is not included in PHP (mostly only on Windows systems) the DateValidator fails to detect invalid dates.

Associated revisions

Revision 091658d3 (diff)
Added by Nicole Cordes over 5 years ago

[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 <>
Tested-by: Oliver Klee <>
Reviewed-by: Steffen Müller <>
Tested-by: Steffen Müller <>

Revision 9afe7460 (diff)
Added by Nicole Cordes over 5 years ago

[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 <>
Reviewed-by: Steffen Müller <>
Tested-by: Steffen Müller <>

History

#1 Updated by Gerrit Code Review over 5 years 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 over 5 years 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 over 5 years 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 over 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#5 Updated by Anja Leichsenring almost 5 years ago

  • Sprint Focus deleted (On Location Sprint)

#6 Updated by Riccardo De Contardi about 3 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF