mirror of
https://github.com/MariaDB/server.git
synced 2025-03-30 11:55:31 +02:00
MDEV-33987 Server crashes at Item_func_as_wkt::val_str_ascii
Item_func_boundary::val_str() did not set null_value when it could not construct a geomery object from the input.
This commit is contained in:
parent
8a3c53f32b
commit
13a14c0d78
3 changed files with 15 additions and 1 deletions
|
@ -5453,4 +5453,10 @@ t2 CREATE TABLE `t2` (
|
|||
`c` polygon DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
|
||||
drop table t1, t2;
|
||||
#
|
||||
# MDEV-33987 Server crashes at Item_func_as_wkt::val_str_ascii
|
||||
#
|
||||
SELECT ST_ASTEXT(BOUNDARY(INET6_ATON('255.255.255.255'))) AS c1;
|
||||
c1
|
||||
NULL
|
||||
# End of 10.5 tests
|
||||
|
|
|
@ -3456,4 +3456,12 @@ create table t2 as select group_concat(c, c order by 1,2), concat(c), c from t1;
|
|||
show create table t2;
|
||||
drop table t1, t2;
|
||||
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-33987 Server crashes at Item_func_as_wkt::val_str_ascii
|
||||
--echo #
|
||||
|
||||
SELECT ST_ASTEXT(BOUNDARY(INET6_ATON('255.255.255.255'))) AS c1;
|
||||
|
||||
|
||||
--echo # End of 10.5 tests
|
||||
|
|
|
@ -452,7 +452,7 @@ String *Item_func_boundary::val_str(String *str_value)
|
|||
Transporter trn(&res_receiver);
|
||||
|
||||
Geometry *g= Geometry::construct(&buffer, swkb->ptr(), swkb->length());
|
||||
if (!g)
|
||||
if ((null_value= !g))
|
||||
DBUG_RETURN(0);
|
||||
|
||||
if (g->store_shapes(&trn))
|
||||
|
|
Loading…
Add table
Reference in a new issue