mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Merge of mysql-5.1-bugteam into mysql-trunk-merge.
This commit is contained in:
@@ -142,11 +142,10 @@ Geometry *Geometry::construct(Geometry_buffer *buffer,
|
||||
{
|
||||
uint32 geom_type;
|
||||
Geometry *result;
|
||||
char byte_order;
|
||||
|
||||
if (data_len < SRID_SIZE + WKB_HEADER_SIZE) // < 4 + (1 + 4)
|
||||
return NULL;
|
||||
byte_order= data[SRID_SIZE];
|
||||
/* + 1 to skip the byte order (stored in position SRID_SIZE). */
|
||||
geom_type= uint4korr(data + SRID_SIZE + 1);
|
||||
if (!(result= create_by_typeid(buffer, (int) geom_type)))
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user