fixes for test failures

and small collateral changes

mysql-test/lib/My/Test.pm:
  somehow with "print" we get truncated writes sometimes
mysql-test/suite/perfschema/r/digest_table_full.result:
  md5 hashes of statement digests differ, because yacc token codes are different in mariadb
mysql-test/suite/perfschema/r/dml_handler.result:
  host table is not ported over yet
mysql-test/suite/perfschema/r/information_schema.result:
  host table is not ported over yet
mysql-test/suite/perfschema/r/nesting.result:
  this differs, because we don't rewrite general log queries, and multi-statement
  packets are logged as a one entry. this result file is identical to what mysql-5.6.5
  produces with the --log-raw option.
mysql-test/suite/perfschema/r/relaylog.result:
  MariaDB modifies the binlog index file directly, while MySQL 5.6 has a feature "crash-safe binlog index" and modifies a special "crash-safe" shadow copy of the index file and then moves it over. That's why this test shows "NONE" index file writes in MySQL and "MANY" in MariaDB.
mysql-test/suite/perfschema/r/server_init.result:
  MariaDB initializes the "manager" resources from the "manager" thread, and starts this thread only when --flush-time is not 0. MySQL 5.6 initializes "manager" resources unconditionally on server startup.
mysql-test/suite/perfschema/r/stage_mdl_global.result:
  this differs, because MariaDB disables query cache when query_cache_size=0. MySQL does not
  do that, and this causes useless mutex locks and waits.
mysql-test/suite/perfschema/r/statement_digest.result:
  md5 hashes of statement digests differ, because yacc token codes are different in mariadb
mysql-test/suite/perfschema/r/statement_digest_consumers.result:
  md5 hashes of statement digests differ, because yacc token codes are different in mariadb
mysql-test/suite/perfschema/r/statement_digest_long_query.result:
  md5 hashes of statement digests differ, because yacc token codes are different in mariadb
mysql-test/suite/rpl/r/rpl_mixed_drop_create_temp_table.result:
  will be updated to match 5.6 when alfranio.correia@oracle.com-20110512172919-c1b5kmum4h52g0ni and anders.song@greatopensource.com-20110105052107-zoab0bsf5a6xxk2y are merged
mysql-test/suite/rpl/r/rpl_non_direct_mixed_mixing_engines.result:
  will be updated to match 5.6 when anders.song@greatopensource.com-20110105052107-zoab0bsf5a6xxk2y is merged
This commit is contained in:
Sergei Golubchik 2012-09-27 20:09:46 +02:00
commit 474fe6d9d9
477 changed files with 33810 additions and 9079 deletions

View file

@ -2015,6 +2015,29 @@ public:
virtual void print_error(int error, myf errflag);
virtual bool get_error_message(int error, String *buf);
uint get_dup_key(int error);
/**
Retrieves the names of the table and the key for which there was a
duplicate entry in the case of HA_ERR_FOREIGN_DUPLICATE_KEY.
If any of the table or key name is not available this method will return
false and will not change any of child_table_name or child_key_name.
@param child_table_name[out] Table name
@param child_table_name_len[in] Table name buffer size
@param child_key_name[out] Key name
@param child_key_name_len[in] Key name buffer size
@retval true table and key names were available
and were written into the corresponding
out parameters.
@retval false table and key names were not available,
the out parameters were not touched.
*/
virtual bool get_foreign_dup_key(char *child_table_name,
uint child_table_name_len,
char *child_key_name,
uint child_key_name_len)
{ DBUG_ASSERT(false); return(false); }
void reset_statistics()
{
rows_read= rows_changed= rows_tmp_read= 0;
@ -2193,18 +2216,17 @@ protected:
}
public:
/* Similar functions like the above, but does statistics counting */
inline int ha_index_read_map(uchar * buf, const uchar * key,
key_part_map keypart_map,
enum ha_rkey_function find_flag);
inline int ha_index_read_idx_map(uchar * buf, uint index, const uchar * key,
key_part_map keypart_map,
enum ha_rkey_function find_flag);
inline int ha_index_next(uchar * buf);
inline int ha_index_prev(uchar * buf);
inline int ha_index_first(uchar * buf);
inline int ha_index_last(uchar * buf);
inline int ha_index_next_same(uchar *buf, const uchar *key, uint keylen);
int ha_index_read_map(uchar * buf, const uchar * key,
key_part_map keypart_map,
enum ha_rkey_function find_flag);
int ha_index_read_idx_map(uchar * buf, uint index, const uchar * key,
key_part_map keypart_map,
enum ha_rkey_function find_flag);
int ha_index_next(uchar * buf);
int ha_index_prev(uchar * buf);
int ha_index_first(uchar * buf);
int ha_index_last(uchar * buf);
int ha_index_next_same(uchar *buf, const uchar *key, uint keylen);
/*
TODO: should we make for those functions non-virtual ha_func_name wrappers,
too?
@ -2276,8 +2298,8 @@ public:
/* Same as above, but with statistics */
inline int ha_ft_read(uchar *buf);
inline int ha_rnd_next(uchar *buf);
inline int ha_rnd_pos(uchar *buf, uchar *pos);
int ha_rnd_next(uchar *buf);
int ha_rnd_pos(uchar *buf, uchar *pos);
inline int ha_rnd_pos_by_record(uchar *buf);
inline int ha_read_first_row(uchar *buf, uint primary_key);
@ -2756,7 +2778,7 @@ private:
*/
virtual int open(const char *name, int mode, uint test_if_locked)=0;
/* Note: ha_index_read_idx_map() may buypass index_init() */
/* Note: ha_index_read_idx_map() may bypass index_init() */
virtual int index_init(uint idx, bool sorted) { return 0; }
virtual int index_end() { return 0; }
/**