Commit c7c2eacf authored by mskold@mysql.com's avatar mskold@mysql.com

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

into mysql.com:/usr/local/home/marty/MySQL/test/mysql-5.0-ndb
parents 9905a520 4c144143
...@@ -44,7 +44,7 @@ select get_lock("a", 10); ...@@ -44,7 +44,7 @@ select get_lock("a", 10);
connection con2; connection con2;
let $ID= `select connection_id()`; let $ID= `select connection_id()`;
send select get_lock("a", 10); send select get_lock("a", 10);
-- sleep 2 --real_sleep 2;
connection con1; connection con1;
disable_query_log; disable_query_log;
eval kill query $ID; eval kill query $ID;
......
...@@ -575,7 +575,7 @@ int ha_archive::create(const char *name, TABLE *table_arg, ...@@ -575,7 +575,7 @@ int ha_archive::create(const char *name, TABLE *table_arg,
int ha_archive::write_row(byte * buf) int ha_archive::write_row(byte * buf)
{ {
z_off_t written; z_off_t written;
uint *ptr, *end; uint *bptr, *end;
DBUG_ENTER("ha_archive::write_row"); DBUG_ENTER("ha_archive::write_row");
if (share->crashed) if (share->crashed)
...@@ -596,16 +596,16 @@ int ha_archive::write_row(byte * buf) ...@@ -596,16 +596,16 @@ int ha_archive::write_row(byte * buf)
We should probably mark the table as damagaged if the record is written We should probably mark the table as damagaged if the record is written
but the blob fails. but the blob fails.
*/ */
for (ptr= table->s->blob_field, end=ptr + table->s->blob_fields ; for (bptr= table->s->blob_field, end=bptr + table->s->blob_fields ;
ptr != end ; bptr != end ;
ptr++) bptr++)
{ {
char *ptr; char *ptr;
uint32 size= ((Field_blob*) table->field[*ptr])->get_length(); uint32 size= ((Field_blob*) table->field[*bptr])->get_length();
if (size) if (size)
{ {
((Field_blob*) table->field[*ptr])->get_ptr(&ptr); ((Field_blob*) table->field[*bptr])->get_ptr(&ptr);
written= gzwrite(share->archive_write, ptr, (unsigned)size); written= gzwrite(share->archive_write, ptr, (unsigned)size);
if (written != size) if (written != size)
goto error; goto error;
......
...@@ -171,6 +171,12 @@ extern CHARSET_INFO *national_charset_info, *table_alias_charset; ...@@ -171,6 +171,12 @@ extern CHARSET_INFO *national_charset_info, *table_alias_charset;
#define FLUSH_TIME 0 /* Don't flush tables */ #define FLUSH_TIME 0 /* Don't flush tables */
#define MAX_CONNECT_ERRORS 10 // errors before disabling host #define MAX_CONNECT_ERRORS 10 // errors before disabling host
#ifdef HAVE_INNOBASE_DB
#define IF_INNOBASE_DB(A, B) (A)
#else
#define IF_INNOBASE_DB(A, B) (B)
#endif
#if defined(__WIN__) || defined(OS2) #if defined(__WIN__) || defined(OS2)
#define IF_WIN(A,B) (A) #define IF_WIN(A,B) (A)
#undef FLUSH_TIME #undef FLUSH_TIME
......
...@@ -1810,9 +1810,8 @@ bool dispatch_command(enum enum_server_command command, THD *thd, ...@@ -1810,9 +1810,8 @@ bool dispatch_command(enum enum_server_command command, THD *thd,
TABLE_LIST table_list; TABLE_LIST table_list;
LEX_STRING conv_name; LEX_STRING conv_name;
/* Saved variable value */ /* Saved variable value */
#ifdef HAVE_INNOBASE_DB my_bool old_innodb_table_locks=
my_bool old_innodb_table_locks= thd->variables.innodb_table_locks; IF_INNOBASE_DB(thd->variables.innodb_table_locks, FALSE);
#endif
statistic_increment(thd->status_var.com_stat[SQLCOM_SHOW_FIELDS], statistic_increment(thd->status_var.com_stat[SQLCOM_SHOW_FIELDS],
...@@ -2340,9 +2339,8 @@ mysql_execute_command(THD *thd) ...@@ -2340,9 +2339,8 @@ mysql_execute_command(THD *thd)
/* Locked closure of all tables */ /* Locked closure of all tables */
TABLE_LIST *locked_tables= NULL; TABLE_LIST *locked_tables= NULL;
/* Saved variable value */ /* Saved variable value */
#ifdef HAVE_INNOBASE_DB my_bool old_innodb_table_locks=
my_bool old_innodb_table_locks= thd->variables.innodb_table_locks; IF_INNOBASE_DB(thd->variables.innodb_table_locks, FALSE);
#endif
DBUG_ENTER("mysql_execute_command"); DBUG_ENTER("mysql_execute_command");
thd->net.no_send_error= 0; thd->net.no_send_error= 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment