Skip to content

Commit f48be8a

Browse files
committed
Merge branch 'bb-10.11-release' into bb-11.4-release
2 parents 42dec0e + c99c705 commit f48be8a

3 files changed

Lines changed: 26 additions & 1 deletion

File tree

libmariadb

mysql-test/main/func_json.result

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1770,6 +1770,21 @@ null<=>json_extract('1',json_object(null,'{ }',null,null),'{}')
17701770
1
17711771
Warnings:
17721772
Warning 4042 Syntax error in JSON path in argument 2 to function 'json_extract' at position 1
1773+
#
1774+
# MDEV-35548 UBSAN: runtime error: index -1 out of bounds for type 'json_path_step_t[32]'
1775+
# (aka 'struct st_json_path_step_t[32]')
1776+
#
1777+
SELECT JSON_EXTRACT('{a:true}','$.a')=TRUE;
1778+
JSON_EXTRACT('{a:true}','$.a')=TRUE
1779+
NULL
1780+
Warnings:
1781+
Warning 4038 Syntax error in JSON text in argument 1 to function 'json_extract' at position 2
1782+
SELECT JSON_EXTRACT('0E+0','$');
1783+
JSON_EXTRACT('0E+0','$')
1784+
0E+0
1785+
SELECT JSON_EXISTS(CONCAT('[', REPEAT('[', 4000), 'Y', REPEAT(']', 4000), ', 1]'), '$[100]') as je;
1786+
je
1787+
NULL
17731788
# End of 10.6 tests
17741789
SELECT json_extract(t.j, '$')
17751790
FROM (SELECT json_extract('["a",1]', '$') AS j) AS t;

mysql-test/main/func_json.test

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1216,6 +1216,16 @@ FROM JSON_TABLE (@data, '$[*]' COLUMNS (data text PATH '$.Data')) AS t;
12161216

12171217
select null<=>json_extract('1',json_object(null,'{ }',null,null),'{}');
12181218

1219+
--echo #
1220+
--echo # MDEV-35548 UBSAN: runtime error: index -1 out of bounds for type 'json_path_step_t[32]'
1221+
--echo # (aka 'struct st_json_path_step_t[32]')
1222+
--echo #
1223+
1224+
SELECT JSON_EXTRACT('{a:true}','$.a')=TRUE;
1225+
SELECT JSON_EXTRACT('0E+0','$');
1226+
1227+
SELECT JSON_EXISTS(CONCAT('[', REPEAT('[', 4000), 'Y', REPEAT(']', 4000), ', 1]'), '$[100]') as je;
1228+
12191229
--echo # End of 10.6 tests
12201230

12211231
SELECT json_extract(t.j, '$')

0 commit comments

Comments
 (0)