Commit graph

9843 commits

Author SHA1 Message Date
unknown
0dc19dadb9 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  chilla.local:/home/mydev/mysql-4.1-axmrg
2007-02-02 20:23:03 +01:00
unknown
98b9ac693a After merge fix 2007-02-02 20:19:13 +01:00
unknown
04cbadde7a another valgrind error fix for 4.1(backport from 5.0) 2007-02-02 17:18:42 +04:00
unknown
5698114c97 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  chilla.local:/home/mydev/mysql-4.1-axmrg


mysql-test/r/symlink.result:
  Auto merged
mysql-test/t/symlink.test:
  Auto merged
sql/mysqld.cc:
  Auto merged
2007-02-01 15:51:25 +01:00
unknown
2df2922586 Valgrind error fixes
Notes:
This patch doesn't fix all issues in the tree and we need jani's fix for that
This patch shoud not be merged into 5.0


mysql-test/r/ps.result:
  result fix
mysql-test/r/symlink.result:
  result fix
mysql-test/t/ps.test:
  test is moved to 'symlink' test
mysql-test/t/symlink.test:
  test from 'ps' test
sql/field_conv.cc:
  valgrind error fix: backport from 5.0
sql/mysqld.cc:
  release of ssl_context
vio/viosslfactories.c:
  release of ssl_context
mysql-test/valgrind.supp:
  New BitKeeper file ``mysql-test/valgrind.supp''
  This file is backported from 5.0, added suppressing of OpenSSL errors
2007-02-01 18:00:24 +04:00
unknown
62fdcb54a7 Merge chilla.local:/home/mydev/mysql-4.0-axmrg
into  chilla.local:/home/mydev/mysql-4.1-axmrg


include/my_global.h:
  Auto merged
include/my_pthread.h:
  Auto merged
include/thr_alarm.h:
  Auto merged
mysys/default.c:
  Auto merged
mysys/my_pthread.c:
  Auto merged
mysys/thr_alarm.c:
  Auto merged
mysys/my_thr_init.c:
  Manual merged
sql/mysqld.cc:
  Manual merged
2007-02-01 08:09:36 +01:00
unknown
a94b1b5077 Merge bk-internal.mysql.com:/home/bk/mysql-4.1-engines
into  chilla.local:/home/mydev/mysql-4.1-axmrg
2007-02-01 07:52:28 +01:00
unknown
f7b3c7c531 WL#3567 - MERGE engine: a check for underlying table conformance
When a merge table is opened compare column and key definition of
underlying tables against column and key definition of merge table.

If any of underlying tables have different column/key definition
refuse to open merge table.


mysql-test/r/merge.result:
  A test case for WL#3456.
mysql-test/t/merge.test:
  A test case for WL#3456.
sql/ha_myisam.cc:
  Moved a part of code that converts TABLE object to MyISAM key and column
  definition to a separate function.
  
  Added check_definition() function that compares MyISAM table definitions.
sql/ha_myisammrg.cc:
  Check if underlying table definition conforms to merge table definition,
  and in case underlying table definition differs, refuse to open merge
  table.
2007-01-31 16:15:20 +04:00
unknown
d308799383 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  chilla.local:/home/mydev/mysql-4.1-axmrg


mysql-test/r/symlink.result:
  Auto merged
mysql-test/t/symlink.test:
  Auto merged
mysql-test/r/myisam.result:
  Manual merged
mysql-test/t/myisam.test:
  Manual merged
2007-01-29 17:20:18 +01:00
unknown
fddf3c3979 Merge mysql.com:/home/gluh/MySQL/Merge/4.1-opt
into  mysql.com:/home/gluh/MySQL/Merge/4.1


sql/item_func.cc:
  Auto merged
2007-01-26 16:28:32 +04:00
unknown
2ec2fa6d08 Cleanup of thread-type (linuxthread or NTPL) detection code
Move get_thread_lib to mysys/my_pthread.c
Set 'thr_client_alarm' to signal number used by thr_alarm to give alarms



include/my_global.h:
  Fixed to be same as in 5.1
include/my_pthread.h:
  Move things around to be more in line with rest of code
include/thr_alarm.h:
  extern of thr_client_alarm
mysys/default.c:
  Fixed two wrong pointer incrementations.
mysys/my_pthread.c:
  Cleanup: Use variable thr_client_alarm
mysys/my_thr_init.c:
  Detect thread library at startup
mysys/thr_alarm.c:
  Set thr_client_alarm depending on which thread library we are using
sql/mysqld.cc:
  Move get_thread_lib to mysys/my_pthread.c
2007-01-25 20:10:31 +02:00
unknown
457d431556 Bug#25668 mysqld may core if cluster disconnected
- recommit in 4.1
2007-01-24 09:41:40 +07:00
unknown
6d04643ab3 Fixed bug #25637: LEFT JOIN with BOOLEAN FULLTEXT loses left table matches.
The bug is actually a duplicate of the bug 14708.
Down-ported the fix for 14708 from 5.0.  
Merged the test case for bug 14708 from 5.0.


mysql-test/r/fulltext_left_join.result:
  Added a test case for bug #25637 (duplicate .of bug 14708).
  Merged the test case for bug 14708 from 5.0.
mysql-test/t/fulltext_left_join.test:
  Added a test case for bug #25637 (duplicate of bug 14708).
  Merged the test case for bug 14708 from 5.0.
sql/item_func.cc:
  Fixed bug #25637: LEFT JOIN with BOOLEAN FULLTEXT loses left table matches.
  The bug is actually a duplicate of the bug 14708.
  Down-ported the fix for 14708 from 5.0.
2007-01-22 14:23:53 -08:00
unknown
077840fa23 Merge a88-113-38-195.elisa-laajakaista.fi:/home/my/bk/mysql-4.0
into  a88-113-38-195.elisa-laajakaista.fi:/home/my/bk/mysql-4.1


include/thr_alarm.h:
  Auto merged
mysys/my_pthread.c:
  Auto merged
BUILD/SETUP.sh:
  Merged from 4.0
configure.in:
  Merged from 4.0
include/my_global.h:
  Merged from 4.0
include/my_pthread.h:
  Merged from 4.0
mysys/thr_alarm.c:
  Merged from 4.0
sql/mysqld.cc:
  Merged from 4.0
BUILD/SETUP.sh.rej:
  Merged from 4.0
configure.in.rej:
  Merged from 4.0
include/my_global.h.rej:
  Merged from 4.0
include/my_pthread.h.rej:
  Merged from 4.0
mysys/thr_alarm.c.rej:
  Merged from 4.0
sql/mysqld.cc.rej:
  Merged from 4.0
2007-01-22 03:33:59 +02:00
unknown
454c763c6b Fix for configure to detect library correctly.
Fix to check library in use during runtime.
Fix for Bug#16995, "idle connections not being killed due to timeout when NPTL is used".


BUILD/SETUP.sh:
  To avoid warnings during compilation.
configure.in:
  Fixed configure so that it can correctly detect
  between NPTL and Linuxthreads.
include/my_global.h:
  Fix for Linuxthreads.
include/my_pthread.h:
  Added defines for different libraries that can be detected.
  Currently only 'other', 'nptl', and 'lt' (linuxthreads) are
  being used.
  
  changed sigset() and signal() to my_sigset() and my_signal()
include/thr_alarm.h:
  Removed defines for Linuxthreads. This is now detected during
  runtime and handled in the thr_alarm.c
mysys/my_pthread.c:
  Runtime check for library.
mysys/thr_alarm.c:
  Runtime checks for library and corresponding
  signals.
sql/mysqld.cc:
  Added function for detecting thread library in use
  during start-up.
  
  THR_KILL_SIGNAL removed, setting signals during runtime.
2007-01-22 02:32:07 +02:00
unknown
3d62df333b Merge siva.hindu.god:/home/tsmith/m/bk/mrg-jan17/41
into  siva.hindu.god:/home/tsmith/m/bk/mrg-jan17/maint/41


sql/sql_show.cc:
  Auto merged
sql/sql_parse.cc:
  Manual merge
2007-01-18 09:53:30 -07:00
unknown
158b0603f3 Merge mysql.com:/nfsdisk1/lars/bkroot/mysql-4.1-rpl
into  mysql.com:/nfsdisk1/lars/MERGE/mysql-4.1-merge


sql/mysql_priv.h:
  Auto merged
sql/sql_parse.cc:
  Auto merged
2007-01-17 19:28:55 +01:00
unknown
f7e41baedb Fix a failure of lowercase_tables2 test on powermacg5, introduced
by the patch for Bug#4968


sql/sql_parse.cc:
  Fix lowercase_tables2 test failure on powermacg5: table_case_name()
  function needed create_info.alias if lowercase_table_names=2, which
  was not set for the stack copy of HA_CREATE_INFO. Move the
  update of create_info.alias from create_table_precheck to 
  mysql_execute_command, so that it is done on the right object.
2007-01-17 15:46:30 +03:00
unknown
4743deeba0 Merge pilot.mysql.com:/home/msvensson/mysql/mysql-4.1
into  pilot.mysql.com:/home/msvensson/mysql/mysql-4.1-maint


mysql-test/t/mysqladmin.test:
  Auto merged
mysys/mf_iocache.c:
  Auto merged
mysys/my_read.c:
  Auto merged
mysys/my_seek.c:
  Auto merged
sql/sql_parse.cc:
  Auto merged
2007-01-17 11:13:03 +01:00
unknown
15c834256d A post-merge fix.
sql/sql_parse.cc:
  A post-merge fix (broken alter_table.test): restore Svoj's fix
  for Bug#23404 lost during merge.
2007-01-15 23:25:16 +03:00
unknown
d470c233f7 Merge bk-internal.mysql.com:/home/bk/mysql-4.1-runtime
into  bodhi.local:/opt/local/work/mysql-4.1-4968-to-push


sql/mysql_priv.h:
  Auto merged
sql/sql_class.h:
  Auto merged
sql/sql_insert.cc:
  Auto merged
sql/sql_parse.cc:
  Manual merge.
sql/sql_table.cc:
  Manual merge.
2007-01-15 13:03:21 +03:00
unknown
b9dc0243a8 Fixed bug #24776: an assertion abort in handler::ha_index_init
for queries using 'range checked for each record'.
The problem was fixed in 5.0 by the patch for bug 12291.
This patch down-ported the corresponding code from 5.0 into 
QUICK_SELECT::init() and added a new test case. 


mysql-test/r/range.result:
  Added a test case for bug #24776.
mysql-test/t/range.test:
  Added a test case for bug #24776.
sql/opt_range.h:
  Fixed bug #24776: an assertion abort in handler::ha_index_init
  for queries using 'range checked for each record'.
  The problem was fixed in 5.0 by the patch for bug 12291.
  The patch for 4.1 down-ported the corresponding code from 5.0 into 
  QUICK_SELECT::init().
2007-01-13 10:49:26 -08:00
unknown
5f9a807562 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  bodhi.local:/opt/local/work/mysql-4.1-runtime
2007-01-12 18:06:43 +03:00
unknown
6dc0202617 Merge mysql.com:/nfsdisk1/lars/bkroot/mysql-4.1-rpl
into  mysql.com:/nfsdisk1/lars/MERGE/mysql-4.1-merge


sql/sql_parse.cc:
  Auto merged
2007-01-12 12:21:44 +01:00
unknown
fcbe66a366 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  bodhi.local:/opt/local/work/mysql-4.1-runtime


sql/item_func.cc:
  Auto merged
2007-01-11 21:49:52 +03:00
unknown
52c100ae0c Bug#23409: Arguments of the ENCODE() and the DECODE() functions were not printed
correctly.

The Item_func::print method was used to print the Item_func_encode and the
Item_func_decode objects. The last argument to ENCODE and DECODE functions
is a plain C string and thus Item_func::print wasn't able to print it.

The print() method is added to the Item_func_encode class. It correctly
prints the Item_func_encode and the Item_func_decode objects.


mysql-test/t/func_str.test:
  Added a test case for bug#23409: Arguments of the ENCODE() and the
  > DECODE() functionswere not printed correctly.
mysql-test/r/func_str.result:
  Added a test case for bug#23409: Arguments of the ENCODE() and the DECODE() functions were not printed correctly.
sql/item_strfunc.h:
  Bug#23409: Arguments of the ENCODE() and the DECODE() functions were not printed correctly.
  The print() method is added to the Item_func_encode class.
sql/item_strfunc.cc:
  Bug#23409: Arguments of the ENCODE() and the DECODE() functions were not printed correctly.
  The print() method is added to the Item_func_encode class. It correctly
  prints the Item_func_encode and the Item_func_decode objects.
2007-01-11 16:45:38 +03:00
unknown
0fdd3dce16 Merge fix for bug#17711 2007-01-11 16:20:08 +03:00
unknown
661796389f Bug#17711: DELETE doesn't use index when ORDER BY, LIMIT and non-restricting
WHERE is present.

If a DELETE statement with ORDER BY and LIMIT contains a WHERE clause
with conditions that for sure cannot be used for index access (like in
WHERE @var:= field) the execution always follows the filesort path.    
It happens currently even when for the above case there is an index that
can be used to speedup sorting by the order by list.

Now if a DELETE statement with ORDER BY and LIMIT contains such WHERE
clause conditions that cannot be used to build any quick select then
the mysql_delete() tries to use an index like there is no WHERE clause at all.


mysql-test/t/delete.test:
  Added a test case for bug#17711: DELETE doesn't use index when ORDER BY, LIMIT and non-restricting
  WHERE is present.
mysql-test/r/delete.result:
  Added a test case for bug#17711: DELETE doesn't use index when ORDER BY, LIMIT and non-restricting WHERE is present.
sql/sql_delete.cc:
  Bug#17711: DELETE doesn't use index when ORDER BY, LIMIT and non-restricting WHERE is present.
  Now if a DELETE statement with ORDER BY and LIMIT contains such WHERE
  clause conditions that cannot be used to build any quick select then
  the mysql_delete() tries to use an index like there is no WHERE clause at all.
2007-01-11 16:05:03 +03:00
unknown
10698df6da Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into  olga.mysql.com:/home/igor/mysql-4.1-opt
2007-01-10 10:49:46 -08:00
unknown
ac71a8fa5e Fix for bug#20867 InnoDB Bug - create temporary table+crash => mysqld needs to clean up
2nd version
During tmp tables cleanup we get the handler for temporary table
and delete table using handler method.


sql/mysql_priv.h:
  added function prototype
sql/mysqld.cc:
  added call of mysql_rm_tmp_tables() function
sql/sql_base.cc:
  mysql_rm_tmp_tables()
  -removed from table_cache_init
  -During tmp tables cleanup we get the handler for temporary table
   and delete table using handler method. 
   it allows to remove orphan records from data dictionary(InnoDB)
2007-01-10 12:57:03 +04:00
unknown
6fc17dab1e Fixed bug #25427.
In the method Item_field::fix_fields we try to resolve the name of
the field against the names of the aliases that occur in the select
list. This is done by a call of the function find_item_in_list.
When this function finds several occurrences of the field name
it sends an error message to the error queue and returns 0.
Yet the code did not take into account that find_item_in_list
could return 0 and tried to dereference the returned value.


mysql-test/r/order_by.result:
  Added a test case for bug #25427.
mysql-test/t/order_by.test:
  Added a test case for bug #25427.
sql/item.cc:
  Fixed bug #25427.
  In the method Item_field::fix_fields we try to resolve the name of
  the field against the names of the aliases that occur in the select
  list. This is done by a call of the function find_item_in_list.
  When this function finds several occurrences of the field name 
  it sends an error message to the error queue and returns 0.
  Yet the code did not take into account that find_item_in_list
  could return 0 and tried to dereference the returned value.
2007-01-10 00:27:11 -08:00
unknown
e5c1d4784d Merge moonlight.home:/home/tomash/src/mysql_ab/mysql-4.1-runtime
into  moonlight.home:/home/tomash/src/mysql_ab/mysql-4.1-bug23443
2007-01-09 12:47:03 +03:00
unknown
2dab449fc7 Merge moonlight.home:/home/tomash/src/mysql_ab/mysql-4.0
into  moonlight.home:/home/tomash/src/mysql_ab/mysql-4.0-bug23443
2007-01-09 12:46:35 +03:00
unknown
beac4a6f8a Merge moonlight.home:/home/tomash/src/mysql_ab/mysql-4.0-bug23443
into  moonlight.home:/home/tomash/src/mysql_ab/mysql-4.1-bug23443


heap/hp_block.c:
  Auto merged
sql/item_func.cc:
  Auto merged
heap/hp_write.c:
  Manual merge.
2007-01-09 12:39:05 +03:00
unknown
4fe1561f98 BUG#23443: user-defined variables can consume too much memory in the
server

The problem was that when memory was exhausted HEAP engine could crash
(GROUP BY uses HEAP TABLE).  Alternatively, if SET was used, it could
report an error "You may only use constant expressions with SET" instead
of "Out of memory (Needed NNNNNN bytes)".

The solution is:
 - pass MY_WME to (some) calls to my_malloc() to get correct message.
 - fix heap_write() so that the first key is skipped during cleanup
   on ENOMEM because it wasn't inserted and doesn't have to be
   deleted.

No test case is provided because we can't test out-of-memory behaviour
in our current test framework.


heap/hp_block.c:
  If allocation fails, write an error message.
heap/hp_write.c:
  On ENOMEM, skip the first key in cleanup, as it wasn't inserted yet.
sql/item_func.cc:
  Add MY_WME so that OOM error will be reported.
2007-01-09 12:24:25 +03:00
unknown
8e0eea0d33 Merge mysql.com:/d2/hf/common/my41-common
into  mysql.com:/d2/hf/opt/my41-opt
2007-01-03 11:17:00 +04:00
unknown
4a12418583 embedded-server related fixes
libmysqld/lib_sql.cc:
  error message moved to 'stmt'
mysql-test/t/distinct.test:
  temporary disabled in embedded server
mysql-test/t/mysqladmin.test:
  disabled in embedded server
sql/sql_prepare.cc:
  superfluous #ifndef removed
2007-01-02 17:46:20 +04:00
unknown
62576974de Merge mysql.com:/d2/hf/clean/my41-clean
into  mysql.com:/d2/hf/common/my41-common


sql/item_func.cc:
  Auto merged
2006-12-31 12:37:42 +04:00
unknown
d26e154c4b Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-4.1-engines
into  mysql.com:/home/svoj/devel/mysql/BUG21310/mysql-4.1-engines
2006-12-29 15:17:07 +04:00
unknown
285dac3fd3 Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-4.1-engines
into  mysql.com:/home/svoj/devel/mysql/BUG24358/mysql-4.1-engines
2006-12-27 15:35:26 +04:00
unknown
0f462179db Merge tsmith@bk-internal.mysql.com:/home/bk/mysql-4.1-maint
into  siva.hindu.god:/usr/home/tim/m/bk/41
2006-12-22 13:23:12 -07:00
unknown
368dcac4f8 Merge polly.local:/tmp/maint/bug24037/my41-bug24037
into  polly.local:/home/kaa/src/maint/mysql-4.1-maint
2006-12-22 16:19:45 +03:00
unknown
ee37cf0bb9 Fix for the bug #24037 "Lossy Hebrew to Unicode conversion".
Added definitions for the following Hebrew characters as specified by the ISO/IEC 8859-8:1999:

LEFT-TO-RIGHT MARK (LRM)
RIGHT-TO-LEFT MARK (RLM)


sql/share/charsets/hebrew.xml:
  Added definitions for the following Hebrew characters as specified by the ISO/IEC 8859-8:1999:
  
  LEFT-TO-RIGHT MARK (LRM)
  RIGHT-TO-LEFT MARK (RLM)
strings/conf_to_src.c:
  Added a warning comment in the generated C source file.
strings/ctype-extra.c:
  Re-generated from sql/share/charsets/hebrew.xml
mysql-test/r/ctype_hebrew.result:
  Added the test case for bug #24037 "Lossy Hebrew to Unicode conversion"
mysql-test/t/ctype_hebrew.test:
  Added the test case for bug #24037 "Lossy Hebrew to Unicode conversion"
2006-12-22 15:30:37 +03:00
unknown
454b7d0f52 Merge siva.hindu.god:/usr/home/tim/m/bk/g41
into  siva.hindu.god:/usr/home/tim/m/bk/41


scripts/mysqld_multi.sh:
  Auto merged
2006-12-21 18:18:27 -07:00
unknown
9d094c56bc Merge mysql.com:/home/svoj/devel/bk/mysql-4.1-engines
into  mysql.com:/home/svoj/devel/mysql/BUG21310/mysql-4.1-engines


sql/sql_update.cc:
  Auto merged
2006-12-20 19:08:28 +04:00
unknown
9d85b0a616 BUG#21310 - Trees in SQL causing a "crashed" table with MyISAM storage engine
An update that used a join of a table to itself and modified the
table on one side of the join reported the table as crashed or
updated wrong rows.

Fixed by creating temporary table for self-joined multi update statement.


mysql-test/r/myisam.result:
  A test case for BUG#21310.
mysql-test/t/myisam.test:
  A test case for BUG#21310.
sql/lock.cc:
  Exclude 'table' param from check.
sql/sql_update.cc:
  Disabling record cache for self-joined multi update statement is wrong.
  The join must only see the table as it was at the beginning of the statement.
  safe_update_on_fly check if it is safe to update first table on the fly, that is
  not creating temporary table. It is possible in case a row from this table is
  never read more than once. safe_update_on_fly now detect self-joined table and
  refuse to update this table on the fly.
2006-12-20 19:05:35 +04:00
unknown
9166c711c2 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  chilla.local:/home/mydev/mysql-4.1-axmrg
2006-12-19 10:40:53 +01:00
unknown
e071fdb632 BUG#24358 - Table access crashes server
Having broken .frm, particulary number of field names does
not match number of fields, causes server crash.

Refuse to open a table if number of field names in a table
is not equal to number of fields in a table.

No test case, since it requires broken .frm file.


sql/table.cc:
  Refuse to open a table if number of field names in a table
  is not equal to number of fields in a table.
2006-12-15 16:01:56 +04:00
unknown
e21242fef8 Merge kpettersson@bk-internal:/home/bk/mysql-4.1-maint
into  naruto.:C:/cpp/mysql-4.1-maint
2006-12-14 16:02:43 +01:00
unknown
a4ad07b7ea Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-4.1-engines
into  mysql.com:/home/svoj/devel/mysql/BUG23404/mysql-4.1-engines


mysql-test/r/alter_table.result:
  SCCS merged
mysql-test/t/alter_table.test:
  SCCS merged
2006-12-13 15:53:37 +04:00