1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 23:18:13 +02:00
Commit Graph

206 Commits

Author SHA1 Message Date
Julien Pauli 1ed4b13fb6 Do not wrap user exception in case of custom JSON serialization 2016-09-19 16:06:12 +02:00
Jakub Zelenka 9f1d962ed6 Fixed bug #72787 (json_decode reads out of bounds) 2016-08-14 13:52:59 +01:00
Lior Kaplan 49493a2dcf Happy new year (Update copyright to 2016) 2016-01-01 19:21:47 +02:00
Jakub Zelenka e5abc53701 Use the same CS for all json tests 2015-11-15 19:06:09 +00:00
Kubo2 f18ba0f9c9 Add tests for json_last_error()/json_last_error_msg() failures 2015-07-21 01:50:40 +02:00
Stanislav Malyshev d66cb721d4 Merge remote-tracking branch 'github/pr/637' into PHP-5.6
* github/pr/637:
  Remove unused code from ext/json.
2015-04-18 17:56:33 -07:00
Jakub Zelenka 97d809a8a5 Merge branch 'PHP-5.5' into PHP-5.6
Conflicts:
	ext/json/json.c
2015-02-22 20:35:03 +00:00
Jakub Zelenka 591dbcabe5 Fix bug #64695 (JSON_NUMERIC_CHECK has issues with strings that are numbers plus the letter e) 2015-02-22 20:22:47 +00:00
Julien Pauli 93315c4e1d Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Revert "json_decode() should generate a syntax error when given ""."
  Update NEWS
2015-02-04 12:48:57 +01:00
Julien Pauli c85f12e3ac Revert "json_decode() should generate a syntax error when given ""."
This reverts commit a7b3abe4e6.
2015-02-04 12:48:17 +01:00
Adam Harvey db375cfd4d Merge branch 'PHP-5.5' into PHP-5.6 2015-02-02 11:11:05 +00:00
Adam Harvey a7b3abe4e6 json_decode() should generate a syntax error when given "".
Fixes bug #68938 (json_decode() decodes empty string without error).
Patch by jeremy at bat-country dot us.
2015-02-02 11:07:34 +00:00
Juan Basso ac7cfad3b5 Fixed bug #50224 where float without decimals were converted to integer 2015-01-19 00:46:02 -08:00
Xinchen Hui 0579e8278d bump year 2015-01-15 23:26:37 +08:00
Xinchen Hui 73c1be2653 Bump year 2015-01-15 23:26:03 +08:00
Lior Kaplan 56d02d564e Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  typofixes
2014-08-17 15:51:15 +03:00
Lior Kaplan be2128c805 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  typofixes
2014-08-17 15:48:22 +03:00
Veres Lajos 3f42f2f5d1 typofixes 2014-08-17 15:44:02 +03:00
Stanislav Malyshev 7c9209a0d1 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fix #66021 (Blank line inside empty array/object)
2014-04-13 18:56:16 -07:00
Stanislav Malyshev 9bba219c75 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fix #66021 (Blank line inside empty array/object)
2014-04-13 18:55:28 -07:00
Stanislav Malyshev 5e66ce9293 Merge branch 'pull-request/518' into PHP-5.4
* pull-request/518:
  Fix #66021 (Blank line inside empty array/object)
2014-04-13 18:50:39 -07:00
Rouven Weßling 7e43b4f908 Remove unused code from ext/json. 2014-03-30 18:06:39 +02:00
Julien Pauli 8a1d248d4e Export JsonSerializable Interface (bug #65753) 2014-02-17 10:38:51 +01:00
Julien Pauli baafdad150 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Export JsonSerializable Interface (bug #65753)
2014-02-17 10:36:13 +01:00
Julien Pauli 786234d351 Export JsonSerializable Interface (bug #65753) 2014-02-17 10:25:40 +01:00
Xinchen Hui c081ce628f Bump year 2014-01-03 11:08:10 +08:00
Xinchen Hui 47c9027772 Bump year 2014-01-03 11:06:16 +08:00
Xinchen Hui c0d060f5c0 Bump year 2014-01-03 11:04:26 +08:00
Andrea Faulds 91779db95b Fixed case part of bug #64874 ("json_decode handles whitespace and case-sensitivity incorrectly") 2013-11-11 22:54:16 +00:00
Adam Harvey 304bff90f4 Merge branch 'PHP-5.4' into PHP-5.5
* 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")
2013-11-10 16:11:28 -05:00
Kevin Israel 82a4f1a1a2 Fix #66021 (Blank line inside empty array/object)
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).
2013-11-02 15:59:11 -04:00
Andrea Faulds 8495d63034 Better test: Check combined leading/trailing 2013-10-15 20:42:31 +00:00
Andrea Faulds 2524428504 Fixed whitespace part of bug #64874 ("json_decode handles whitespace and case-sensitivity incorrectly") 2013-09-17 19:09:52 +00:00
Veres Lajos 4749457a49 HASH_KEY_NON_EXISTANT fix 2013-07-21 20:09:53 -07:00
Xinchen Hui a666285bc2 Happy New Year 2013-01-01 16:37:09 +08:00
Xinchen Hui 0a7395e009 Happy New Year 2013-01-01 16:28:54 +08:00
Adam Harvey 8bb106d20c Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Alter php_json_decode_ex() to respect JSON_BIGINT_AS_STRING for bare numbers.
2012-12-11 19:53:02 +08:00
Adam Harvey 2d1694d4eb Alter php_json_decode_ex() to respect JSON_BIGINT_AS_STRING for bare numbers.
Fixes bug #63737 (json_decode does not properly decode with options parameter).
2012-12-11 19:51:30 +08:00
Remi Collet 495ff0964d Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Related bug #63588 fix length computation + optimize for speed
2012-11-26 13:05:37 +01:00
Remi Collet 7751a68824 Related bug #63588 fix length computation + optimize for speed
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.
2012-11-26 12:59:08 +01:00
Remi Collet f4a8612561 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fixed bug #63588 Duplicate implementation of php_next_utf8_char
2012-11-25 08:21:10 +01:00
Remi Collet 289bb339c9 Fixed bug #63588 Duplicate implementation of php_next_utf8_char
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.
2012-11-25 08:14:23 +01:00
Nikita Popov f3192ea6e4 Fix 64bit JSON test 2012-08-13 18:43:03 +02:00
Xinchen Hui f8559194db Fix test failed due to new feature introduced in 45d596ea 2012-07-29 23:35:06 +08:00
Florian Anderiasch 45d596ea1e Add optional depth parameter to json_encode #62369 2012-07-24 13:15:16 +02:00
Nikita Popov b7903f9778 Revert JSON merges to 5.4
This reverts the following merge commits (-m 1):

405ebfcd18
d372b33c9b
36fa17a5fa
2012-07-01 16:38:26 +02:00
Stanislav Malyshev b741d3315b fix bug #61359: json_encode() calls too many reallocs 2012-06-30 19:14:30 -07:00
Nikita Popov 405ebfcd18 Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Add json_last_error_msg() function
2012-06-28 20:18:19 +02:00
Nikita Popov 974324676b Add json_last_error_msg() function
This replaces json_last_error(true) and is consistent with other custom
error handling functions.
2012-06-28 20:11:27 +02:00
Nikita Popov d372b33c9b Merge branch 'PHP-5.3' into PHP-5.4
* PHP-5.3:
  Improve JSON error handling

Conflicts:
	ext/json/tests/bug54058.phpt
	ext/json/tests/bug61537.phpt
2012-06-27 12:28:55 +02:00