Bug #63520 [Com]: JSON extension includes a problematic license statement
Edit report at https://bugs.php.net/bug.php?id=63520&edit=1 ID: 63520 Comment by: kap...@php.net Reported by:kaplan at debian dot org Summary:JSON extension includes a problematic license statement Status: Assigned Type: Bug Package:JSON related PHP Version:Irrelevant Assigned To:remi Block user comment: N Private report: N New Comment: Stas: We (PHP) provide the code, and the eco system clearly has a problem with it. We could either keep ignoring it while they provide a replacement code, or adopt it officially to make everyone happy. Previous Comments: [2013-08-22 21:52:19] shitty at gmail dot com Not evil???... come on!!! [2013-08-21 18:47:57] s...@php.net How this is a PHP bug? [2013-07-17 15:18:33] r...@php.net @seld Mandriva/Fedora/Debian have drop json non-free extension but provides jsonc dropin alternative (php5-json 1.3.1 for debian). So, your comment is not PHP related. See debian packager to have this package installed when needed (pulled by main php package for Fedora). [2013-07-17 14:24:32] s...@php.net What's the status here Remi? Can we have a regular Debian release including the JSON ext before this hits testing/stable? We had a first issue on Composer today because someone was missing the json ext [1], using Ubuntu 13.10. If this isn't resolved soon Ubuntu's next release won't have json enabled by default and we'll have a support shitstorm on our hands, so please don't do Evil because of a dubious license statement. Given the prevalence of JSON APIs and such these days, it's not just Composer that will be affected, so removing it before having a replacement in place was really an unhelpful decision IMO. [1] https://github.com/composer/composer/issues/2092 [2013-04-27 10:40:22] r...@php.net Yes, I'm still working on the new alternative extension. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=63520 -- Edit this bug report at https://bugs.php.net/bug.php?id=63520&edit=1
Bug #48539 [PATCH]: pdo_dblib fails to connect, throws empty PDOException "SQLSTATE[] (null)"
Edit report at https://bugs.php.net/bug.php?id=48539&edit=1 ID: 48539 Patch added by: kap...@php.net Reported by:frase at cs dot wisc dot edu Summary:pdo_dblib fails to connect, throws empty PDOException "SQLSTATE[] (null)" Status: Closed Type: Bug Package:PDO related Operating System: * PHP Version:5.2.10, 5.3.0RC4 Assigned To:felipe Block user comment: N Private report: N New Comment: The following patch has been added/updated: Patch Name: mssql-null-exception Revision: 1380120958 URL: https://bugs.php.net/patch-display.php?bug=48539&patch=mssql-null-exception&revision=1380120958 Previous Comments: [2013-05-09 10:15:06] talktome at aboutandrew dot co dot uk This problem exists in php 5.4.10 [2012-12-13 16:08:25] wdmeldon at gmail dot com I've tested this in 5.3.19 and was not able to replicate. [2012-07-13 13:10:20] snowcorenet at gmail dot com Could anyone tell me, please, if this is fixed in php 5.3? [2011-04-11 18:37:18] tom at punkave dot com Did this fix ever get put in PHP 5.3? I am getting this error exactly as originally described with all PHP 5.3.x versions tried. [2009-06-28 02:10:33] fel...@php.net This bug has been fixed in CVS. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. Thank you for the report, and for helping us make PHP better. Fixed in 5.2 and HEAD. 5.3 in soon. Thanks. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=48539 -- Edit this bug report at https://bugs.php.net/bug.php?id=48539&edit=1
Bug #54973 [Com]: SimpleXML casts intergers wrong.
Edit report at https://bugs.php.net/bug.php?id=54973&edit=1 ID: 54973 Comment by: kap...@php.net Reported by:bphelpsen at gmail dot com Summary:SimpleXML casts intergers wrong. Status: Analyzed Type: Bug Package:SimpleXML related Operating System: Linux PHP Version:5.3.6 Block user comment: N Private report: N New Comment: The referenced pull request (#213) has two tests to verify the fix for this bug (when and if ready). Please don't forget to use them when commiting the fix. Previous Comments: [2011-06-03 11:55:06] cataphr...@php.net I remember seeing this before. The problem is that the Zend engine, when doing the add operation, converts any objects it finds to ints. The simplexml extension is merely doing what it's asked, i.e., convert the value of the object to int. The solution must be either a) making the Zend Engine default the conversion to a double b) making the Zend Engine try both a double and an int and compare the two results c) making the Zend Engine convert the object to a string instead and then convert the string using the usual means (that is, is_numeric_string) d) change the API so that cast_object can be told to convert the object to either an int or a double, sort of like is_numeric_string [2011-06-02 22:14:14] dtajchre...@php.net This looks like a bug... SimpleXML's cast_object handler doesn't check for overflow when trying to convert a node value to a long. $xml->value goes through Zend's add_function and gets passed to zendi_convert_scalar_to_number which calls SimpleXML's cast_object handler because $xml->number is an object. It then gets chopped into LONG_MAX by strtol. An overflow check could fix this... but it might break some BC [1] http://lxr.php.net/xref/PHP_5_3/Zend/zend_operators.c#758 [2] http://lxr.php.net/xref/PHP_5_3/ext/simplexml/simplexml.c#1722 [3] http://lxr.php.net/xref/PHP_5_3/Zend/zend_operators.c#355 [4] http://lxr.php.net/xref/PHP_5_3/Zend/zend_operators.c#768 [5] http://www.gnu.org/s/hello/manual/libc/Parsing-of-Integers.html [2011-06-02 20:05:07] bphelpsen at gmail dot com Then why do I get different results when I run this code: than when I run the example code. Shouldn't they return the same value? Here is an example, with the same results as my local test: http://codepad.org/KICl3xHw [2011-06-02 20:00:54] il...@php.net Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php This has nothing to do with SimpleXML, but rather the fact that a numeric string in PHP by default would converted to an integer. [2011-06-01 22:18:27] bphelpsen at gmail dot com Description: When an XML node value is an integer SimpleXML always casts it to an int, even if its a float or double. Test script: --- 214748364800"); echo $xml->number . "\n"; // the proper number $int = $xml->number / 1024 / 1024 / 1024; // initial cast to an int causes problems echo $int . "\n"; $double = (double) $xml->number / 1024 / 1024 / 1024; // hard cast to a double fixes it echo $double . "\n"; ?> Expected result: 214748364800 200 200 Actual result: -- 214748364800 1.90687 200 -- Edit this bug report at https://bugs.php.net/bug.php?id=54973&edit=1