Commit 206281e4 authored by unknown's avatar unknown
Browse files

Merge poseidon.ndb.mysql.com:/home/tomas/mysql-4.1

into poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-ndb

parents 1768d464 3302dee5
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -101,6 +101,7 @@ magnus@neptunus.(none)
magnus@shellback.(none)
marko@hundin.mysql.fi
matt@mysql.com
matthias@three.local.lan
miguel@hegel.(none)
miguel@hegel.br
miguel@hegel.local
+29 −1
Original line number Diff line number Diff line
@@ -243,6 +243,8 @@ VAR var_reg[10];
HASH var_hash;
my_bool disable_query_log=0, disable_result_log=0, disable_warnings=0;
my_bool disable_info= 1;			/* By default off */
/* default for disable_abort_on_error: false = abort on unmasked error */
my_bool disable_abort_on_error= 0;

struct connection cons[MAX_CONS];
struct connection* cur_con, *next_con, *cons_end;
@@ -274,6 +276,7 @@ Q_ENABLE_WARNINGS, Q_DISABLE_WARNINGS,
Q_ENABLE_INFO, Q_DISABLE_INFO,
Q_ENABLE_METADATA, Q_DISABLE_METADATA,
Q_EXEC, Q_DELIMITER,
Q_DISABLE_ABORT_ON_ERROR, Q_ENABLE_ABORT_ON_ERROR,
Q_DISPLAY_VERTICAL_RESULTS, Q_DISPLAY_HORIZONTAL_RESULTS,
Q_QUERY_VERTICAL, Q_QUERY_HORIZONTAL,
Q_START_TIMER, Q_END_TIMER,
@@ -352,6 +355,8 @@ const char *command_names[]=
  "disable_metadata",
  "exec",
  "delimiter",
  "disable_abort_on_error",
  "enable_abort_on_error",
  "vertical_results",
  "horizontal_results",
  "query_vertical",
@@ -1239,6 +1244,18 @@ int do_let(struct st_query* q)
  return var_set(var_name, var_name_end, var_val_start, q->end);
}

/* Store an integer (typically the returncode of the last SQL)  */
/* statement in the mysqltest builtin variable $mysql_errno, by */
/* simulating of a user statement "let $mysql_errno= <integer>" */
int var_set_errno(int sql_errno )
{
  char var_name[] = "$mysql_errno", var_val[30];
  sprintf(var_val, "%d", sql_errno);
  /* On some odd systems, the return value from sprintf() isn't */
  /* always the length of the string, so we use strlen()        */
   return var_set(var_name, var_name + 12, var_val, var_val + strlen(var_val));
}

int do_rpl_probe(struct st_query* q __attribute__((unused)))
{
  DBUG_ENTER("do_rpl_probe");
@@ -1996,7 +2013,7 @@ int read_query(struct st_query** q_ptr)
  memcpy((gptr) q->expected_errno, (gptr) global_expected_errno,
	 sizeof(global_expected_errno));
  q->expected_errors= global_expected_errors;
  q->abort_on_error= global_expected_errors == 0;
  q->abort_on_error= (global_expected_errors == 0 && !disable_abort_on_error);
  bzero((gptr) global_expected_errno, sizeof(global_expected_errno));
  global_expected_errors=0;
  if (p[0] == '-' && p[1] == '-')
@@ -2642,6 +2659,10 @@ static int run_query_normal(MYSQL* mysql, struct st_query* q, int flags)
    dynstr_free(&ds_tmp);
  if (q->type == Q_EVAL)
    dynstr_free(&eval_query);
  /* We save the return code (mysql_errno(mysql)) from the last call sent */
  /* to the server into the mysqltest builtin variable $mysql_errno. This */
  /* variable then can be used from the test case itself.                 */
  var_set_errno(mysql_errno(mysql));
  DBUG_RETURN(error);
}

@@ -3395,6 +3416,11 @@ int main(int argc, char **argv)

  init_var_hash(&cur_con->mysql);

  /* Initialize $mysql_errno with -1, so we can                  */
  /* - distinguish it from valid values ( >= 0 )   and           */
  /* - detect if there was never a command sent to the server    */
  var_set_errno(-1);

  while (!read_query(&q))
  {
    int current_line_inc = 1, processed = 0;
@@ -3414,6 +3440,8 @@ int main(int argc, char **argv)
      case Q_DISABLE_RPL_PARSE:  do_disable_rpl_parse(q); break;
      case Q_ENABLE_QUERY_LOG:	 disable_query_log=0; break;
      case Q_DISABLE_QUERY_LOG:  disable_query_log=1; break;
      case Q_ENABLE_ABORT_ON_ERROR:  disable_abort_on_error=0; break;
      case Q_DISABLE_ABORT_ON_ERROR: disable_abort_on_error=1; break;
      case Q_ENABLE_RESULT_LOG:  disable_result_log=0; break;
      case Q_DISABLE_RESULT_LOG: disable_result_log=1; break;
      case Q_ENABLE_WARNINGS:    disable_warnings=0; break;
+8 −6
Original line number Diff line number Diff line
@@ -4,6 +4,7 @@ dnl Process this file with autoconf to produce a configure script.
AC_INIT(sql/mysqld.cc)
AC_CANONICAL_SYSTEM
# The Docs Makefile.am parses this line!
# remember to also change ndb version below and update version.c in ndb
AM_INIT_AUTOMAKE(mysql, 4.1.8)
AM_CONFIG_HEADER(config.h)

@@ -13,9 +14,9 @@ DOT_FRM_VERSION=6
SHARED_LIB_VERSION=14:0:0

# ndb version
NDB_VERSION_MAJOR=3
NDB_VERSION_MINOR=5
NDB_VERSION_BUILD=3
NDB_VERSION_MAJOR=4
NDB_VERSION_MINOR=1
NDB_VERSION_BUILD=8
NDB_VERSION_STATUS=""

# Set all version vars based on $VERSION. How do we do this more elegant ?
@@ -1142,9 +1143,10 @@ dnl Is this the right match for DEC OSF on alpha?
      fi
      echo "Adding defines for OSF1"
      # gethostbyname_r is deprecated and doesn't work ok on OSF1
      CFLAGS="$CFLAGS -DUNDEF_HAVE_GETHOSTBYNAME_R"
      CXXFLAGS="$CXXFLAGS -DUNDEF_HAVE_GETHOSTBYNAME_R"
      ndb_cxxflags_fix="$ndb_cxxflags_fix -I/usr/include.dtk"
      CFLAGS="$CFLAGS -DUNDEF_HAVE_GETHOSTBYNAME_R -DSNPRINTF_RETURN_TRUNC"
      CXXFLAGS="$CXXFLAGS -DUNDEF_HAVE_GETHOSTBYNAME_R -DSNPRINTF_RETURN_TRUNC"
      # fix to handle include of <stdint.h> correctly on OSF1 with cxx compiler
      CXXFLAGS="$CXXFLAGS -I/usr/include/cxx -I/usr/include/cxx_cname -I/usr/include -I/usr/include.dtk"
    ;;
  *netware*)
    # No need for curses library so set it to null
+1 −1
Original line number Diff line number Diff line
@@ -2037,7 +2037,7 @@ int mi_repair_by_sort(MI_CHECK *param, register MI_INFO *info,
      uint ft_max_word_len_for_sort=FT_MAX_WORD_LEN_FOR_SORT*
                                    sort_param.keyinfo->seg->charset->mbmaxlen;
      sort_info.max_records=
        (ha_rows) (sort_info.filelength/ft_max_word_len_for_sort+1);
        (ha_rows) (sort_info.filelength/ft_min_word_len+1);

      sort_param.key_read=sort_ft_key_read;
      sort_param.key_write=sort_ft_key_write;
+4 −1
Original line number Diff line number Diff line
@@ -322,8 +322,11 @@ select a,b from t1 where a >= 1000 order by a ;
delete from t1 where a >= 1000 ;

## replace
--error 1295
prepare stmt1 from ' replace into t1 (a,b) select 100, ''hundred'' ';
execute stmt1;
execute stmt1;
execute stmt1;



## multi table statements
Loading