Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix type conversions #313

Merged
merged 1 commit into from
Dec 14, 2019
Merged

Fix type conversions #313

merged 1 commit into from
Dec 14, 2019

Conversation

tomsommer
Copy link
Contributor

@tomsommer tomsommer commented Jun 13, 2019

Calling SvNV() for magical scalar is not enough for float type conversion.
It caused problem for Amavis in tainted mode -- all float values were zero.
On the other hand SvIV() and SvUV() seems to work fine. To be sure that
correct value of float is in scalar use sv_setnv() with explicit NV float
value. Similar code is changed also for integers IV/UV.

Fixes #78
Fixes #312

Credit kentnl-gentoo@b6b8540

Calling SvNV() for magical scalar is not enough for float type conversion.
It caused problem for Amavis in tainted mode -- all float values were zero.
On the other hand SvIV() and SvUV() seems to work fine. To be sure that
correct value of float is in scalar use sv_setnv() with explicit NV float
value. Similar code is changed also for integers IV/UV.

Fixes perl5-dbi#78, perl5-dbi#312 

Credit kentnl-gentoo@b6b8540
@dveeden dveeden merged commit b20d572 into perl5-dbi:master Dec 14, 2019
@tomsommer tomsommer deleted the patch-1 branch December 14, 2019 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BIGINT type error conversion with amavisd-new Problems with type conversions
2 participants