Development

#4158 (sfYaml does not handle long numeric values correctly)

You must first sign up to be able to contribute.

Ticket #4158 (closed defect: fixed)

Opened 5 years ago

Last modified 5 years ago

sfYaml does not handle long numeric values correctly

Reported by: guilhermeblanco Assigned to: hartym
Priority: minor Milestone:
Component: other Version: 1.0.17
Keywords: yaml, integer, overflow, cast Cc:
Qualification: Ready for core team

Description

Recently we merged sfYaml package as Data_Parser of Doctrine project.

We found that when we have a numeric value that should be considered as a string (for example: phone number, CPF (brazilian ID card), the parser tries to cast the value into integer type, which lead to a dubeous value after processment.

I wrote a patch that prevents this cast in the case of integer overflow and consider it as a normal string, which fixed our failing tests related to this issue.

Here is the link of the changeset I made to fix it: http://trac.phpdoctrine.org/changeset/4758

I'm available for explanations at IRC channel #doctrine @ freenode.

Regards,

Guilherme Blanco

Change History

08/14/08 10:11:07 changed by hartym

  • owner changed from fabien to hartym.
  • status changed from new to assigned.

08/14/08 10:13:36 changed by hartym

  • status changed from assigned to closed.
  • resolution set to fixed.

(In [10880]) [1.2] fixes #4158

08/14/08 10:14:11 changed by hartym

(In [10881]) [1.1] fixes #4158