1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

Merge with MySQL 5.1.55

- Fixed some issues with partitions and connection_string, which also fixed lp:716890 "Pre- and post-recovery crash in Aria"
- Fixed wrong assert in Aria

Now need to merge with latest xtradb before pushing 

sql/ha_partition.cc:
  Ensure that m_ordered_rec_buffer is not freed before close.
sql/mysqld.cc:
  Changed to use opt_stack_trace instead of opt_pstack.
  Removed references to pstack
sql/partition_element.h:
  Ensure that connect_string is initialized
storage/maria/ma_key_recover.c:
  Fixed wrong assert
This commit is contained in:
Michael Widenius
2011-02-20 18:51:43 +02:00
1288 changed files with 19581 additions and 38443 deletions

View File

@ -1,4 +1,4 @@
/* Copyright 2007 MySQL AB. All rights reserved.
/* Copyright 2007 MySQL AB.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@ -180,8 +180,7 @@ int
unpack_row(Relay_log_info const *rli,
TABLE *table, uint const colcnt,
uchar const *const row_data, MY_BITMAP const *cols,
uchar const **const row_end, ulong *const master_reclength,
const bool abort_on_warning, const bool first_row)
uchar const **const row_end, ulong *const master_reclength)
{
DBUG_ENTER("unpack_row");
DBUG_ASSERT(row_data);
@ -251,22 +250,9 @@ unpack_row(Relay_log_info const *rli,
}
else
{
MYSQL_ERROR::enum_warning_level error_type=
MYSQL_ERROR::WARN_LEVEL_NOTE;
if (abort_on_warning && (table->file->has_transactions() ||
first_row))
{
error = HA_ERR_ROWS_EVENT_APPLY;
error_type= MYSQL_ERROR::WARN_LEVEL_ERROR;
}
else
{
f->set_default();
error_type= MYSQL_ERROR::WARN_LEVEL_WARN;
}
push_warning_printf(current_thd, error_type,
ER_BAD_NULL_ERROR,
ER(ER_BAD_NULL_ERROR),
f->set_default();
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN,
ER_BAD_NULL_ERROR, ER(ER_BAD_NULL_ERROR),
f->field_name);
}
}
@ -350,20 +336,13 @@ unpack_row(Relay_log_info const *rli,
@param skip Number of columns for which default/nullable check
should be skipped.
@param check Specifies if lack of default error needs checking.
@param abort_on_warning
Controls how to react on lack of a field's default.
The parameter mimics the master side one for
@c check_that_all_fields_are_given_values.
@returns 0 on success or a handler level error code
*/
int prepare_record(TABLE *const table,
const uint skip, const bool check,
const bool abort_on_warning, const bool first_row)
int prepare_record(TABLE *const table, const uint skip, const bool check)
{
DBUG_ENTER("prepare_record");
int error= 0;
restore_record(table, s->default_values);
/*
@ -386,28 +365,16 @@ int prepare_record(TABLE *const table,
if ((f->flags & NO_DEFAULT_VALUE_FLAG) &&
(f->real_type() != MYSQL_TYPE_ENUM))
{
MYSQL_ERROR::enum_warning_level error_type=
MYSQL_ERROR::WARN_LEVEL_NOTE;
if (abort_on_warning && (table->file->has_transactions() ||
first_row))
{
error= HA_ERR_ROWS_EVENT_APPLY;
error_type= MYSQL_ERROR::WARN_LEVEL_ERROR;
}
else
{
f->set_default();
error_type= MYSQL_ERROR::WARN_LEVEL_WARN;
}
push_warning_printf(current_thd, error_type,
f->set_default();
push_warning_printf(current_thd,
MYSQL_ERROR::WARN_LEVEL_WARN,
ER_NO_DEFAULT_FOR_FIELD,
ER(ER_NO_DEFAULT_FOR_FIELD),
f->field_name);
}
}
DBUG_RETURN(error);
DBUG_RETURN(0);
}
#endif // HAVE_REPLICATION