summaryrefslogtreecommitdiff
path: root/ext/json/json.c
Commit message (Collapse)AuthorAgeFilesLines
...
* | | Merge branch 'PHP-5.6'Lior Kaplan2014-08-171-1/+1
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | * PHP-5.6: typofixes Conflicts: ext/spl/php_spl.c
| * | Merge branch 'PHP-5.5' into PHP-5.6Lior Kaplan2014-08-171-1/+1
| |\ \ | | |/ | | | | | | | | | * PHP-5.5: typofixes
| | * Merge branch 'PHP-5.4' into PHP-5.5Lior Kaplan2014-08-171-1/+1
| | |\ | | | | | | | | | | | | | | | | * PHP-5.4: typofixes
| | | * typofixesVeres Lajos2014-08-171-1/+1
| | | |
* | | | Use reference counting instead of zval duplicationDmitry Stogov2014-06-051-1/+1
| | | |
* | | | Introduced immutable arrays. They don't need to be copyed and may be used ↵Dmitry Stogov2014-05-291-2/+2
| | | | | | | | | | | | | | | | directly from SHM.
* | | | Fixed Reference handling in xml_parse_into_structXinchen Hui2014-05-051-3/+0
| | | |
* | | | Port JSONNikita Popov2014-05-051-114/+97
| | | |
* | | | Merge branch 'PHP-5.6'Stanislav Malyshev2014-04-131-8/+10
|\ \ \ \ | |/ / / | | | | | | | | | | | | * PHP-5.6: Fix #66021 (Blank line inside empty array/object)
| * | | Merge branch 'PHP-5.5' into PHP-5.6Stanislav Malyshev2014-04-131-8/+10
| |\ \ \ | | |/ / | | | | | | | | | | | | * PHP-5.5: Fix #66021 (Blank line inside empty array/object)
| | * | Merge branch 'PHP-5.4' into PHP-5.5Stanislav Malyshev2014-04-131-8/+10
| | |\ \ | | | |/ | | | | | | | | | | | | * PHP-5.4: Fix #66021 (Blank line inside empty array/object)
| | | * Merge branch 'pull-request/518' into PHP-5.4Stanislav Malyshev2014-04-131-8/+10
| | | |\ | | | | | | | | | | | | | | | | | | | | * pull-request/518: Fix #66021 (Blank line inside empty array/object)
| | | | * Fix #66021 (Blank line inside empty array/object)Kevin Israel2013-11-021-8/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changed json_encode() so that when the JSON_PRETTY_PRINT option is specified, the pair of linefeeds immediately after an opening bracket and before the corresponding closing bracket is omitted when the array or object contains no elements or accessible properties (and hence would have a blank line between the brackets).
| | * | | Merge branch 'PHP-5.4' into PHP-5.5Julien Pauli2014-02-171-1/+1
| | |\ \ \ | | | |/ / | | | | | | | | | | | | | | | * PHP-5.4: Export JsonSerializable Interface (bug #65753)
| | | * | Export JsonSerializable Interface (bug #65753)Julien Pauli2014-02-171-1/+1
| | | | |
| | | * | Bump yearXinchen Hui2014-01-031-1/+1
| | | | |
| | * | | Bump yearXinchen Hui2014-01-031-1/+1
| | | | |
| * | | | Export JsonSerializable Interface (bug #65753)Julien Pauli2014-02-171-1/+1
| | | | |
* | | | | Export JsonSerializable Interface (bug #65753)Julien Pauli2014-02-171-1/+1
| | | | |
* | | | | Merge branch 'PHP-5.6'Xinchen Hui2014-01-031-1/+1
|\ \ \ \ \ | |/ / / /
| * | | | Bump yearXinchen Hui2014-01-031-1/+1
| | | | |
* | | | | Merge branch 'PHP-5.6'kovacs.ferenc2013-11-181-3/+3
|\ \ \ \ \ | |/ / / /
| * | | | Fixed case part of bug #64874 ("json_decode handles whitespace and ↵Andrea Faulds2013-11-111-3/+3
| |/ / / | | | | | | | | | | | | case-sensitivity incorrectly")
* | | | Merge branch 'PHP-5.6'Adam Harvey2013-11-101-8/+22
|\ \ \ \ | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.6: Update NEWS and remove the unnecessary UPGRADING note. UPGRADING and NEWS Better test: Check combined leading/trailing Fixed whitespace part of bug #64874 ("json_decode handles whitespace and case-sensitivity incorrectly")
| * | | Merge branch 'PHP-5.4' into PHP-5.5Adam Harvey2013-11-101-8/+22
| |\ \ \ | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.4: Update NEWS and remove the unnecessary UPGRADING note. UPGRADING and NEWS Better test: Check combined leading/trailing Fixed whitespace part of bug #64874 ("json_decode handles whitespace and case-sensitivity incorrectly")
| | * | Fixed whitespace part of bug #64874 ("json_decode handles whitespace and ↵Andrea Faulds2013-09-171-8/+22
| | |/ | | | | | | | | | case-sensitivity incorrectly")
| | * Happy New YearXinchen Hui2013-01-011-1/+1
| | |
* | | Make all code paths in json_determine_array_type() return constants.Adam Harvey2013-11-091-2/+2
|/ / | | | | | | | | This is a purely cosmetic change, but the current behaviour of returning PHP_JSON_OUTPUT_ARRAY and 1 looks weird.
* | HASH_KEY_NON_EXISTANT fixVeres Lajos2013-07-211-2/+2
| |
* | Happy New YearXinchen Hui2013-01-011-1/+1
| |
* | Merge branch 'PHP-5.4' into PHP-5.5Adam Harvey2012-12-111-3/+28
|\ \ | |/ | | | | | | * PHP-5.4: Alter php_json_decode_ex() to respect JSON_BIGINT_AS_STRING for bare numbers.
| * Alter php_json_decode_ex() to respect JSON_BIGINT_AS_STRING for bare numbers.Adam Harvey2012-12-111-3/+28
| | | | | | | | Fixes bug #63737 (json_decode does not properly decode with options parameter).
* | Merge branch 'PHP-5.4' into PHP-5.5Remi Collet2012-11-261-17/+22
|\ \ | |/ | | | | | | * PHP-5.4: Related bug #63588 fix length computation + optimize for speed
| * Related bug #63588 fix length computation + optimize for speedRemi Collet2012-11-261-17/+22
| | | | | | | | | | | | Following comment from Yoram "The patch looks fine, except of testing for true value of utf16 in each iteration." Also fix the length computation during check phase.
* | Merge branch 'PHP-5.4' into PHP-5.5Remi Collet2012-11-251-3/+29
|\ \ | |/ | | | | | | * PHP-5.4: Fixed bug #63588 Duplicate implementation of php_next_utf8_char
| * Fixed bug #63588 Duplicate implementation of php_next_utf8_charRemi Collet2012-11-251-3/+29
| | | | | | | | | | | | | | | | | | Json use an utf8 parser from a third party library, switch to our implementation of php_next_utf8_char. This also helps on solving #63520. All the unit tests succeed. Our implementation also seems a little faster. json.dsp need to be regenerated.
| * Revert JSON merges to 5.4Nikita Popov2012-07-011-54/+10
| | | | | | | | | | | | | | | | This reverts the following merge commits (-m 1): 405ebfcd182a39f0960ff7d7055d49053d3e0316 d372b33c9b941be9a795bf3705bd22dc5f6092c3 36fa17a5fae84ab332366a202f0a709279a2466a
* | Fix test failed due to new feature introduced in 45d596eaXinchen Hui2012-07-291-1/+1
| |
* | Add optional depth parameter to json_encode #62369Florian Anderiasch2012-07-241-1/+9
|/
* fix bug #61359: json_encode() calls too many reallocsStanislav Malyshev2012-06-301-9/+12
|
* Merge branch 'PHP-5.3' into PHP-5.4Nikita Popov2012-06-281-10/+19
|\ | | | | | | | | * PHP-5.3: Add json_last_error_msg() function
| * Add json_last_error_msg() functionNikita Popov2012-06-281-10/+19
| | | | | | | | | | This replaces json_last_error(true) and is consistent with other custom error handling functions.
* | Merge branch 'PHP-5.3' into PHP-5.4Nikita Popov2012-06-271-9/+33
|\ \ | |/ | | | | | | | | | | | | | | * PHP-5.3: Improve JSON error handling Conflicts: ext/json/tests/bug54058.phpt ext/json/tests/bug61537.phpt
| * Improve JSON error handlingNikita Popov2012-06-271-8/+33
| | | | | | | | | | | | | | | | | | json_encode() no longer throws warnings. Instead only the error code for json_last_error() is set. As it is hard to debug the error from just an error code an optional $as_string parameter was added to json_last_error(), which returns an error message instead of an error code.
* | Merge branch 'PHP-5.3' into PHP-5.4Nikita Popov2012-06-231-7/+18
|\ \ | |/ | | | | | | | | | | | | | | * PHP-5.3: Improve json_encode error handling - BFN Conflicts: ext/json/json.c
| * Improve json_encode error handlingNikita Popov2012-06-231-4/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | json_encode() now returns bool(false) for all possible errors, throws the respective warning and also sets the respective json_last_error() error code. Three new error codes have been added: * JSON_ERROR_RECURSION * JSON_ERROR_INF_OR_NAN * JSON_ERROR_UNSUPPORTED_TYPE To get a partial JSON output instead of bool(false) the option JSON_PARTIAL_OUTPUT_ON_ERROR can be specified. In this case the invalid segments will be replaced either by null (for recursion, unsupported type and invalid JSON) or 0 (for Inf and NaN). The warning for invalid UTF-8 stays intact and is thrown also with display_errors = On. If this behavior is undesired this can be remedied later.
| * Fix bug #61537 (json_encode() incorrectly truncates/discards information) andAdam Harvey2012-04-111-4/+7
| | | | | | | | remove a test case that's now mooted by this fix.
* | - Fixed bug #61978 (Object recursion not detected for classes that implement ↵Felipe Pena2012-05-081-0/+13
| | | | | | | | JsonSerializable)
* | Revert "Fix bug #61537 (json_encode() incorrectly truncates/discards ↵Stanislav Malyshev2012-05-011-7/+4
| | | | | | | | | | | | | | | | information) and" This reverts commit cb2a1c71c96d7c9b2ee03d77beae0c8e0d385f1b. The fix is not correct, not fixed after discussion on github. Please fix the issues and reapply the patch
* | Fix bug #61537 (json_encode() incorrectly truncates/discards information) andAdam Harvey2012-04-111-4/+7
| | | | | | | | remove a test case that's now mooted by this fix.