Commit b923c068 authored by unknown's avatar unknown

Merge paul@bk-internal.mysql.com:/home/bk/mysql-4.1

into teton.kitebird.com:/home/paul/mysql-4.1

parents 357b2ceb 2746e7de
...@@ -74,7 +74,6 @@ INC_LIB= $(top_builddir)/regex/libregex.a \ ...@@ -74,7 +74,6 @@ INC_LIB= $(top_builddir)/regex/libregex.a \
$(top_builddir)/mysys/libmysys.a \ $(top_builddir)/mysys/libmysys.a \
$(top_builddir)/strings/libmystrings.a \ $(top_builddir)/strings/libmystrings.a \
$(top_builddir)/dbug/libdbug.a \ $(top_builddir)/dbug/libdbug.a \
$(top_builddir)/regex/libregex.a \
$(top_builddir)/vio/libvio.a $(top_builddir)/vio/libvio.a
# #
......
...@@ -96,6 +96,7 @@ emb_advanced_command(MYSQL *mysql, enum enum_server_command command, ...@@ -96,6 +96,7 @@ emb_advanced_command(MYSQL *mysql, enum enum_server_command command,
net->last_error[0]= 0; net->last_error[0]= 0;
strmov(net->sqlstate, not_error_sqlstate); strmov(net->sqlstate, not_error_sqlstate);
} }
mysql->server_status= thd->server_status;
mysql->warning_count= ((THD*)mysql->thd)->total_warn_count; mysql->warning_count= ((THD*)mysql->thd)->total_warn_count;
return result; return result;
} }
...@@ -484,7 +485,7 @@ int check_embedded_connection(MYSQL *mysql) ...@@ -484,7 +485,7 @@ int check_embedded_connection(MYSQL *mysql)
THD *thd= (THD*)mysql->thd; THD *thd= (THD*)mysql->thd;
thd->host= (char*)my_localhost; thd->host= (char*)my_localhost;
thd->host_or_ip= thd->host; thd->host_or_ip= thd->host;
thd->user= mysql->user; thd->user= my_strdup(mysql->user, MYF(0));
return 0; return 0;
} }
...@@ -498,8 +499,8 @@ int check_embedded_connection(MYSQL *mysql) ...@@ -498,8 +499,8 @@ int check_embedded_connection(MYSQL *mysql)
if (mysql->options.client_ip) if (mysql->options.client_ip)
{ {
thd->host= mysql->options.client_ip; thd->host= my_strdup(mysql->options.client_ip, MYF(0));
thd->ip= thd->host; thd->ip= my_strdup(thd->host, MYF(0));
} }
else else
thd->host= (char*)my_localhost; thd->host= (char*)my_localhost;
...@@ -511,7 +512,7 @@ int check_embedded_connection(MYSQL *mysql) ...@@ -511,7 +512,7 @@ int check_embedded_connection(MYSQL *mysql)
goto err; goto err;
} }
thd->user= mysql->user; thd->user= my_strdup(mysql->user, MYF(0));
if (mysql->passwd && mysql->passwd[0]) if (mysql->passwd && mysql->passwd[0])
{ {
memset(thd->scramble, 55, SCRAMBLE_LENGTH); // dummy scramble memset(thd->scramble, 55, SCRAMBLE_LENGTH); // dummy scramble
......
...@@ -323,13 +323,11 @@ THD::~THD() ...@@ -323,13 +323,11 @@ THD::~THD()
#endif #endif
DBUG_PRINT("info", ("freeing host")); DBUG_PRINT("info", ("freeing host"));
#ifndef EMBEDDED_LIBRARY
if (host != my_localhost) // If not pointer to constant if (host != my_localhost) // If not pointer to constant
safeFree(host); safeFree(host);
if (user != delayed_user) if (user != delayed_user)
safeFree(user); safeFree(user);
safeFree(ip); safeFree(ip);
#endif
safeFree(db); safeFree(db);
free_root(&warn_root,MYF(0)); free_root(&warn_root,MYF(0));
free_root(&transaction.mem_root,MYF(0)); free_root(&transaction.mem_root,MYF(0));
......
...@@ -1833,6 +1833,7 @@ slave: ...@@ -1833,6 +1833,7 @@ slave:
lex->type = 0; lex->type = 0;
/* We'll use mi structure for UNTIL options */ /* We'll use mi structure for UNTIL options */
bzero((char*) &lex->mi, sizeof(lex->mi)); bzero((char*) &lex->mi, sizeof(lex->mi));
/* If you change this code don't forget to update SLAVE START too */
} }
slave_until slave_until
{} {}
...@@ -1841,6 +1842,7 @@ slave: ...@@ -1841,6 +1842,7 @@ slave:
LEX *lex=Lex; LEX *lex=Lex;
lex->sql_command = SQLCOM_SLAVE_STOP; lex->sql_command = SQLCOM_SLAVE_STOP;
lex->type = 0; lex->type = 0;
/* If you change this code don't forget to update SLAVE STOP too */
} }
| SLAVE START_SYM slave_thread_opts | SLAVE START_SYM slave_thread_opts
{ {
......
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