Commit a7e23091 authored by unknown's avatar unknown
Browse files

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

into ice.snake.net:/Volumes/ice2/MySQL/bk/mysql-4.1


sql/mysqld.cc:
  Auto merged
parents 567d754e 5347ea97
Loading
Loading
Loading
Loading
+27 −16
Original line number Diff line number Diff line
@@ -155,25 +155,32 @@ enum enum_field_types { FIELD_TYPE_DECIMAL, FIELD_TYPE_TINY,
#define FIELD_TYPE_CHAR FIELD_TYPE_TINY		/* For compability */
#define FIELD_TYPE_INTERVAL FIELD_TYPE_ENUM	/* For compability */


/* Shutdown/kill enums and constants */ 

/* Bits for THD::killable. */
#define KILLABLE_CONNECT    (unsigned char)(1 << 0)
#define KILLABLE_TRANS      (unsigned char)(1 << 1)
#define KILLABLE_LOCK_TABLE (unsigned char)(1 << 2)
#define KILLABLE_UPDATE     (unsigned char)(1 << 3)

enum enum_shutdown_level {
  /*
    We want levels to be in growing order of hardness. So we leave room
    for future intermediate levels. For now, escalating one level is += 10;
    later if we insert new levels in between we will need a function
    next_shutdown_level(level). Note that DEFAULT does not respect the
    growing property.
    We want levels to be in growing order of hardness (because we use number
    comparisons). Note that DEFAULT does not respect the growing property, but
    it's ok.
  */
  SHUTDOWN_DEFAULT= 0, /* mapped to WAIT_ALL_BUFFERS for now */
  /*
    Here is the list in growing order (the next does the previous plus
    something). WAIT_ALL_BUFFERS is what we have now. Others are "this MySQL
    server does not support this shutdown level yet".
  */
  SHUTDOWN_WAIT_CONNECTIONS= 10, /* wait for existing connections to finish */
  SHUTDOWN_WAIT_TRANSACTIONS= 20, /* wait for existing trans to finish */
  SHUTDOWN_WAIT_STATEMENTS= 30, /* wait for existing updating stmts to finish */
  SHUTDOWN_WAIT_ALL_BUFFERS= 40, /* flush InnoDB buffers */
  SHUTDOWN_WAIT_CRITICAL_BUFFERS= 50, /* flush MyISAM buffs (no corruption) */
  SHUTDOWN_DEFAULT= 0,
  /* wait for existing connections to finish */
  SHUTDOWN_WAIT_CONNECTIONS= KILLABLE_CONNECT,
  /* wait for existing trans to finish */
  SHUTDOWN_WAIT_TRANSACTIONS= KILLABLE_TRANS,
  /* wait for existing updates to finish (=> no partial MyISAM update) */
  SHUTDOWN_WAIT_UPDATES= KILLABLE_UPDATE,
  /* flush InnoDB buffers and other storage engines' buffers*/
  SHUTDOWN_WAIT_ALL_BUFFERS= (KILLABLE_UPDATE << 1),
  /* don't flush InnoDB buffers, flush other storage engines' buffers*/
  SHUTDOWN_WAIT_CRITICAL_BUFFERS= (KILLABLE_UPDATE << 1) + 1,
  /* Now the 2 levels of the KILL command */
#if MYSQL_VERSION_ID >= 50000
  KILL_QUERY= 254,
@@ -181,6 +188,10 @@ enum enum_shutdown_level {
  KILL_CONNECTION= 255
};

/* Same value and type (0, enum_shutdown_level) but not same meaning */
#define NOT_KILLED SHUTDOWN_DEFAULT


extern unsigned long max_allowed_packet;
extern unsigned long net_buffer_length;

+2 −2
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@ static struct my_option my_long_options[] =
   NO_ARG, 0, 0, 0, 0, 0, 0},
#ifdef HAVE_NDBCLUSTER_DB
  {"ndb", 0, "Ndbcluster storage engine specific error codes.",  (gptr*) &ndb_code,
   (gptr*) &ndb_code, 0, GET_BOOL, NO_ARG, 1, 0, 0, 0, 0, 0},
   (gptr*) &ndb_code, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
#endif
#ifdef HAVE_SYS_ERRLIST
  {"all", 'a', "Print all the error messages and the number.",
@@ -222,7 +222,7 @@ int main(int argc,char *argv[])
#ifdef HAVE_NDBCLUSTER_DB
      if (ndb_code)
      {
	if (ndb_error_string(code, ndb_string, 1024) < 0)
	if (ndb_error_string(code, ndb_string,  sizeof(ndb_string)) < 0)
	  msg= 0;
	else
	  msg= ndb_string;
+27 −16
Original line number Diff line number Diff line
@@ -223,25 +223,32 @@ enum enum_field_types { MYSQL_TYPE_DECIMAL, MYSQL_TYPE_TINY,
#define FIELD_TYPE_INTERVAL    MYSQL_TYPE_ENUM
#define FIELD_TYPE_GEOMETRY    MYSQL_TYPE_GEOMETRY


/* Shutdown/kill enums and constants */ 

/* Bits for THD::killable. */
#define KILLABLE_CONNECT    (unsigned char)(1 << 0)
#define KILLABLE_TRANS      (unsigned char)(1 << 1)
#define KILLABLE_LOCK_TABLE (unsigned char)(1 << 2)
#define KILLABLE_UPDATE     (unsigned char)(1 << 3)

enum enum_shutdown_level {
  /*
    We want levels to be in growing order of hardness. So we leave room
    for future intermediate levels. For now, escalating one level is += 10;
    later if we insert new levels in between we will need a function
    next_shutdown_level(level). Note that DEFAULT does not respect the
    growing property.
    We want levels to be in growing order of hardness (because we use number
    comparisons). Note that DEFAULT does not respect the growing property, but
    it's ok.
  */
  SHUTDOWN_DEFAULT= 0, /* mapped to WAIT_ALL_BUFFERS for now */
  /*
    Here is the list in growing order (the next does the previous plus
    something). WAIT_ALL_BUFFERS is what we have now. Others are "this MySQL
    server does not support this shutdown level yet".
  */
  SHUTDOWN_WAIT_CONNECTIONS= 10, /* wait for existing connections to finish */
  SHUTDOWN_WAIT_TRANSACTIONS= 20, /* wait for existing trans to finish */
  SHUTDOWN_WAIT_STATEMENTS= 30, /* wait for existing updating stmts to finish */
  SHUTDOWN_WAIT_ALL_BUFFERS= 40, /* flush InnoDB buffers */
  SHUTDOWN_WAIT_CRITICAL_BUFFERS= 50, /* flush MyISAM buffs (no corruption) */
  SHUTDOWN_DEFAULT= 0,
  /* wait for existing connections to finish */
  SHUTDOWN_WAIT_CONNECTIONS= KILLABLE_CONNECT,
  /* wait for existing trans to finish */
  SHUTDOWN_WAIT_TRANSACTIONS= KILLABLE_TRANS,
  /* wait for existing updates to finish (=> no partial MyISAM update) */
  SHUTDOWN_WAIT_UPDATES= KILLABLE_UPDATE,
  /* flush InnoDB buffers and other storage engines' buffers*/
  SHUTDOWN_WAIT_ALL_BUFFERS= (KILLABLE_UPDATE << 1),
  /* don't flush InnoDB buffers, flush other storage engines' buffers*/
  SHUTDOWN_WAIT_CRITICAL_BUFFERS= (KILLABLE_UPDATE << 1) + 1,
  /* Now the 2 levels of the KILL command */
#if MYSQL_VERSION_ID >= 50000
  KILL_QUERY= 254,
@@ -249,6 +256,10 @@ enum enum_shutdown_level {
  KILL_CONNECTION= 255
};

/* Same value and type (0, enum_shutdown_level) but not same meaning */
#define NOT_KILLED SHUTDOWN_DEFAULT


/* options for mysql_set_option */
enum enum_mysql_set_option
{
+1 −1
Original line number Diff line number Diff line
@@ -18,7 +18,7 @@ extern uint mysql_port;
extern my_string	mysql_unix_port;

#define CLIENT_CAPABILITIES (CLIENT_LONG_PASSWORD | CLIENT_LONG_FLAG |	  \
                             CLIENT_LOCAL_FILES | CLIENT_TRANSACTIONS |   \
                             CLIENT_TRANSACTIONS | \
			     CLIENT_PROTOCOL_41 | CLIENT_SECURE_CONNECTION)

sig_handler pipe_sig_handler(int sig __attribute__((unused)));
+3 −0
Original line number Diff line number Diff line
@@ -155,3 +155,6 @@ select * from t1 where a like '%ESKA%';
a
PPUH PESKA-I Maria Struniarska
DROP TABLE t1;
select _cp866'aaaaaaaaa' like _cp866'%aaaa%' collate cp866_bin;
_cp866'aaaaaaaaa' like _cp866'%aaaa%' collate cp866_bin
1
Loading