1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Fix for a crashing bug

This commit is contained in:
Sinisa@sinisa.nasamreza.org
2003-03-08 22:19:41 +02:00
parent 3ee8d6e37e
commit dafa51eced

View File

@ -7088,7 +7088,7 @@ find_order_in_list(THD *thd, Item **ref_pointer_array,
Item *item=0;
uint count= (uint) ((Item_int*)itemptr)->value;
if (count > fields.elements)
if (!count || count > fields.elements)
{
my_printf_error(ER_BAD_FIELD_ERROR,ER(ER_BAD_FIELD_ERROR),
MYF(0),itemptr->full_name(),