Merge pnousiainen@bk-internal.mysql.com:/home/bk/mysql-5.0

into mysql.com:/export/space/pekka/ndb/version/my50
This commit is contained in:
unknown 2005-04-21 12:55:19 +02:00
commit bfe12fdb8d

View file

@ -1187,7 +1187,7 @@ static void shrink_varchar(Field* field, const byte* & ptr, char* buf)
{
if (field->type() == MYSQL_TYPE_VARCHAR) {
Field_varstring* f= (Field_varstring*)field;
if (f->length_bytes < 256) {
if (f->length_bytes == 1) {
uint pack_len= field->pack_length();
DBUG_ASSERT(1 <= pack_len && pack_len <= 256);
if (ptr[1] == 0) {