mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-19723 Assertion je->state == JST_KEY' failed while SELECT ST_GEOMFROMGEOJSON() and Assertion
!mysql_bin_log.is_open() || thd.is_current_stmt_binlog_format_row()'
The invalid GeoJSON case wasn't handled here.
This commit is contained in:
@@ -104,6 +104,9 @@ a
|
|||||||
NULL
|
NULL
|
||||||
Warnings:
|
Warnings:
|
||||||
Warning 4076 Incorrect GeoJSON format - empty 'coordinates' array.
|
Warning 4076 Incorrect GeoJSON format - empty 'coordinates' array.
|
||||||
|
SELECT ST_GEOMFROMGEOJSON("{ \"type\": \"Feature\", \"geometry\": [10, 20] }");
|
||||||
|
ST_GEOMFROMGEOJSON("{ \"type\": \"Feature\", \"geometry\": [10, 20] }")
|
||||||
|
NULL
|
||||||
#
|
#
|
||||||
# End of 10.2 tests
|
# End of 10.2 tests
|
||||||
#
|
#
|
||||||
|
@@ -44,6 +44,8 @@ SELECT st_astext(st_geomfromgeojson('{"type": "MultiLineString","coordinates": [
|
|||||||
SELECT st_astext(st_geomfromgeojson('{"type": "Polygon","coordinates": []}')) as a;
|
SELECT st_astext(st_geomfromgeojson('{"type": "Polygon","coordinates": []}')) as a;
|
||||||
SELECT st_astext(st_geomfromgeojson('{"type": "MultiPolygon","coordinates": []}')) as a;
|
SELECT st_astext(st_geomfromgeojson('{"type": "MultiPolygon","coordinates": []}')) as a;
|
||||||
|
|
||||||
|
SELECT ST_GEOMFROMGEOJSON("{ \"type\": \"Feature\", \"geometry\": [10, 20] }");
|
||||||
|
|
||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.2 tests
|
--echo # End of 10.2 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
@@ -605,6 +605,7 @@ Geometry *Geometry::create_from_json(Geometry_buffer *buffer,
|
|||||||
if (feature_type_found)
|
if (feature_type_found)
|
||||||
goto handle_geometry_key;
|
goto handle_geometry_key;
|
||||||
}
|
}
|
||||||
|
goto err_return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user