summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <msvensson@neptunus.(none)>2005-03-23 13:25:31 +0100
committerunknown <msvensson@neptunus.(none)>2005-03-23 13:25:31 +0100
commita3762d793e1484a4d4569d554bf19c115abd5e1f (patch)
tree382dad56dc74ecbf4c964b54e155cb0408fd3e7f
parent226628d12e70201d0dcea969dbf30b3183fd32a5 (diff)
parent3315fab91e02012b01783afa7cba02b43c5ae425 (diff)
downloadmariadb-git-a3762d793e1484a4d4569d554bf19c115abd5e1f.tar.gz
Merge neptunus.(none):/home/msvensson/mysql/mysql-4.1
into neptunus.(none):/home/msvensson/mysql/mysql-5.0 mysql-test/r/warnings.result: Auto merged mysql-test/t/warnings.test: Auto merged sql/mysqld.cc: Auto merged
-rw-r--r--mysql-test/r/warnings.result19
-rw-r--r--mysql-test/t/warnings.test13
-rw-r--r--sql/mysqld.cc2
3 files changed, 33 insertions, 1 deletions
diff --git a/mysql-test/r/warnings.result b/mysql-test/r/warnings.result
index 222638f64bb..d143b66ae94 100644
--- a/mysql-test/r/warnings.result
+++ b/mysql-test/r/warnings.result
@@ -142,6 +142,25 @@ Warning 1265 Data truncated for column 'b' at row 10
select @@warning_count;
@@warning_count
50
+set max_error_count=0;
+show variables like 'max_error_count';
+Variable_name Value
+max_error_count 0
+update t1 set b='hi';
+Warnings:
+select @@warning_count;
+@@warning_count
+50
+show warnings;
+Level Code Message
+set max_error_count=65535;
+show variables like 'max_error_count';
+Variable_name Value
+max_error_count 65535
+set max_error_count=10;
+show variables like 'max_error_count';
+Variable_name Value
+max_error_count 10
drop table t1;
create table t1 (id int) engine=isam;
Warnings:
diff --git a/mysql-test/t/warnings.test b/mysql-test/t/warnings.test
index c71365c3da6..69284b4c6e4 100644
--- a/mysql-test/t/warnings.test
+++ b/mysql-test/t/warnings.test
@@ -96,6 +96,19 @@ update t1 set b=a;
select @@warning_count;
--enable_ps_protocol
+# Bug#9072
+set max_error_count=0;
+show variables like 'max_error_count';
+update t1 set b='hi';
+--disable_ps_protocol
+select @@warning_count;
+--enable_ps_protocol
+show warnings;
+set max_error_count=65535;
+show variables like 'max_error_count';
+set max_error_count=10;
+show variables like 'max_error_count';
+
#
# Test for handler type
#
diff --git a/sql/mysqld.cc b/sql/mysqld.cc
index ecaa7ace841..6eed46975fb 100644
--- a/sql/mysqld.cc
+++ b/sql/mysqld.cc
@@ -5225,7 +5225,7 @@ The minimum value for this variable is 4096.",
"Max number of errors/warnings to store for a statement.",
(gptr*) &global_system_variables.max_error_count,
(gptr*) &max_system_variables.max_error_count,
- 0, GET_ULONG, REQUIRED_ARG, DEFAULT_ERROR_COUNT, 1, 65535, 0, 1, 0},
+ 0, GET_ULONG, REQUIRED_ARG, DEFAULT_ERROR_COUNT, 0, 65535, 0, 1, 0},
{"max_heap_table_size", OPT_MAX_HEP_TABLE_SIZE,
"Don't allow creation of heap tables bigger than this.",
(gptr*) &global_system_variables.max_heap_table_size,