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 for mysqli bugs #68114 and #68657 #983

Closed
wants to merge 3 commits into from

Conversation

3 participants
@keyurdg
Copy link
Contributor

commented Jan 6, 2015

I put the float_to_double() method into ext/standard but if there's a better location, please let me know and I'll fix it up.

With this patch, floating point values from PDO+libmysqlclient match mysqli's values both with mysqlnd and libmysqlclient.

keyurdg added some commits Jan 6, 2015

Fix for bugs #68114 (Build fails on OS X due to undefined symbols)
and #68657 (Reading 4 byte floats with Mysqli and libmysqlclient
has rounding errors).

The patch removes support for Decimal floating point numbers and
now defaults to using similar logic as what libmysqlclient does:
convert a 4 byte floating point number into a string, and then the
string into a double. The quirks of MySQL are maintained as seen in
Field_Float::val_str()
@laruence

This comment has been minimized.

Copy link
Member

commented Jan 6, 2015

I am not sure why it (only one function)needs a separate new file?

@keyurdg

This comment has been minimized.

Copy link
Contributor Author

commented Jan 6, 2015

@laruence I could just make it a static inline function in a header file and move it to ext/msysqlnd if that's preferable.

I put it into a separate file just as a personal style preference.

@keyurdg keyurdg closed this Jan 7, 2015

@keyurdg

This comment has been minimized.

Copy link
Contributor Author

commented Jan 7, 2015

Merged!

@remicollet

This comment has been minimized.

Copy link
Contributor

commented Jan 22, 2015

This have be applied only in master.

But the mysqlnd.so size increase from 200K to >2M in 5.5 / 5.6.
Also need to be fixed there

@laruence

This comment has been minimized.

Copy link
Member

commented Jan 23, 2015

@remicollet wow, how could that be?

@keyurdg

This comment has been minimized.

Copy link
Contributor Author

commented Jan 26, 2015

For some reason the commits in the PHP-5.5 and 5.6 branches didn't get pushed to origin. I pushed them in and now things should be back to normal.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.