diff options
author | unknown <guilhem@mysql.com> | 2004-08-23 16:15:57 +0200 |
---|---|---|
committer | unknown <guilhem@mysql.com> | 2004-08-23 16:15:57 +0200 |
commit | e9c25d9336c8d1266254df5f795366e7d280de85 (patch) | |
tree | 473c7951f1ebf8ee281da1848e8cadc3e2cf68e1 /mysql-test/mysql-test-run.sh | |
parent | 38b8c98543e68b3185a491b3cb9fb9d48662ef14 (diff) | |
download | mariadb-git-e9c25d9336c8d1266254df5f795366e7d280de85.tar.gz |
Fix for BUG#5033 "When using temporary tables truncate does NOT reset the auto_increment counter"
(ok'd by CTO to fix it in 4.0).
Fix to make mysql-test-run work with all Valgrind versions.
mysql-test/mysql-test-run.sh:
fixing mysql-test-run.sh so that it works indifferently with Valgrind 1.x, 2.x
(versions <= 2.0.0 refuse --tool option; versions >=2.1.2 require it; 2.1.0 accepts it).
I hope the shell code is portable enough; anyway Valgrind only runs on Linux...
I tested it with 2.0.0, 2.1.0, 2.1.2.
mysql-test/r/truncate.result:
result update
mysql-test/t/truncate.test:
testing if TRUNCATE resets autoinc counter for temp tables (BUG#5033); testing difference with DELETE FROM.
sql/sql_delete.cc:
in mysql_truncate(), always reset the autoinc counter, as manual says (even if it's a temp table, which was BUG#5033).
Diffstat (limited to 'mysql-test/mysql-test-run.sh')
-rw-r--r-- | mysql-test/mysql-test-run.sh | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mysql-test/mysql-test-run.sh b/mysql-test/mysql-test-run.sh index cd6c331687f..d47560fe7a6 100644 --- a/mysql-test/mysql-test-run.sh +++ b/mysql-test/mysql-test-run.sh @@ -349,9 +349,11 @@ while test $# -gt 0; do VALGRIND=`which valgrind` # this will print an error if not found # Give good warning to the user and stop if [ -z "$VALGRIND" ] ; then - $ECHO "You need to have the 'valgrind' program in your PATH to run mysql-test-run with option --valgrind. Valgrind's home page is http://developer.kde.org/~sewardj ." + $ECHO "You need to have the 'valgrind' program in your PATH to run mysql-test-run with option --valgrind. Valgrind's home page is http://valgrind.kde.org ." exit 1 fi + # >=2.1.2 requires the --tool option, some versions write to stdout, some to stderr + valgrind --help 2>&1 | grep "\-\-tool" > /dev/null && VALGRIND="$VALGRIND --tool=memcheck" VALGRIND="$VALGRIND --alignment=8 --leak-check=yes --num-callers=16" EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT --skip-safemalloc --skip-bdb" EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT --skip-safemalloc --skip-bdb" |