Commit graph

81 commits

Author SHA1 Message Date
Georgi Kodinov
7234ca1a44 Bug #42366: server-cert.pem expired: "Not After : Jan 27 08:54:13 2009 GMT"
Re-generated the PKI files needed.
Removed the ones that are not needed.
Updated the tests to reference the correct SSL subject.
2009-01-28 16:18:50 +02:00
Georgi Kodinov
8f36a23c00 Bug #39920: MySQL cannot deal with Leap Second expression in string literal.
Updated MySQL time handling code to react correctly on UTC leap second additions.
MySQL functions that return the OS current time, like e.g. CURDATE(), NOW() etc
will return :59:59 instead of :59:60 or 59:61.
As a result the reader will receive :59:59 for 2 or 3 consecutive seconds 
during the leap second.
This fix will not affect the values returned by UNIX_TIMESTAMP() for leap seconds.
But note that when converting the value returned by UNIX_TIMESTAMP() to broken 
down time the correction of leap seconds will still be applied.
Note that this fix will make a difference *only* if the OS is specially configured
to return leap seconds from the OS time calls or when using a MySQL time zone 
defintion that has leap seconds.
Even after this change date/time literals (or other broken down time 
representations) with leap seconds (ending on :59:60 or 59:61) will still be 
considered illegal and discarded by the server with an error or 
a warning depending on the sql mode.
Added a test case to demonstrate the effect of the fix.
2008-12-01 16:18:35 +02:00
gshchepa/uchum@host.loc
486ef1bad6 Merge host.loc:/work/bugs/5.0-bugteam-36055
into  host.loc:/work/bk/5.0-bugteam
2008-05-13 00:32:43 +05:00
gshchepa/uchum@host.loc
1e7be565e2 Fixed bug #36055: mysql_upgrade doesn't really 'upgrade' tables
The REPAIR TABLE ... USE_FRM query silently corrupts data of tables
with old .FRM file version.
The mysql_upgrade client program or the REPAIR TABLE query (without
the USE_FRM clause) can't prevent this trouble, because in the
common case they don't upgrade .FRM file to compatible structure.

1. Evaluation of the REPAIR TABLE ... USE_FRM query has been
   modified to reject such tables with the message:
   "Failed repairing incompatible .FRM file".

2. REPAIR TABLE query (without USE_FRM clause) evaluation has been
   modified to upgrade .FRM files to current version.

3. CHECK TABLE ... FOR UPGRADE query evaluation has been modified
   to return error status when .FRM file has incompatible version.

4. mysql_upgrade and mysqlcheck client programs call CHECK TABLE
   FOR UPGRADE and REPAIR TABLE queries, so their behaviors have
   been changed too to upgrade .FRM files with incompatible
   version numbers.
2008-05-12 21:01:13 +05:00
mleich@five.local.lan
4f4d10da03 Merge mleich@bk-internal.mysql.com:/home/bk/mysql-5.0-build
into  five.local.lan:/work/trees/mysql-5.0-build-src-clean
2008-04-02 14:55:35 +02:00
mleich@five.local.lan
89ddc0aa52 Fix for
Bug#35335 funcs_1: Some tests fail within load_file during
                      pushbuild runs
   Solution: 1. Move files with input data used in load_file, 
                load data etc. 
                from suite/funcs_1/<whatever>
                to std_data
             2. Use for testsuite funcs_1 the server option
                --secure-file-priv=<MYSQLTEST_VARDIR>
             3. Outfiles have to be stored under MYSQLTEST_VARDIR 
+ changes according to WL#4304 Cleanup in funcs_1 tests
  - backport of fixes/improvements made in 5.1 to 5.0
    The differences between scripts in 5.0 and 5.1 cause
    much additional and annoying work during any upmerge.
  - replace error numbers with names
  - improved comments
  - improved formatting
  - Unify storage engine names so that result files for
    storage engine variants do not differ (some tests)
  - remove a script no more used (tests are done in other scripts)
2008-03-31 19:48:02 +02:00
anozdrin/alik@quad.opbmk
814e2613b0 Fix tree:
1. Use 'dat' extension, because it is handled in Makefile.am;
  2. Fix typo: the bug id is 35469, not 35649.
2008-03-28 23:39:47 +03:00
anozdrin/alik@quad.opbmk
2880d2081e Fix for Bug#35469: server crash with LOAD DATA INFILE to a VIEW.
The problem was that LOAD DATA code (sql_load.cc) didn't take into
account that there may be items, representing references to other
columns. This is a usual case in views. The crash happened because
Item_direct_view_ref was casted to Item_user_var_as_out_param,
which is not a base class.

The fix is to
  1) Handle references properly;
  2) Ensure that an item is treated as a user variable only when
     it is a user variable indeed;
  3) Report an error if LOAD DATA is used to load data into
     non-updatable column.
2008-03-28 18:59:13 +03:00
aelkin/elkin@koti.dsl.inet.fi
c5b597bc89 bug#30435
changes due to non-determinism in value of read_buffer_size.
2007-12-23 11:18:46 +02:00
mats@capulet.net
a432d3dec4 BUG#31793 (log event corruption causes crash):
When running mysqlbinlog on a 64-bit machine with a corrupt relay log,
it causes mysqlbinlog to crash. In this case, the crash is caused
because a request for 18446744073709534806U bytes is issued, which
apparantly can be served on a 64-bit machine (speculatively, I assume)
but this causes the memcpy() issued later to copy the data to segfault.

The request for the number of bytes is caused by a computation
of data_len - server_vars_len where server_vars_len is corrupt in such
a sense that it is > data_len. This causes a wrap-around, with the
the data_len given above.

This patch adds a check that if server_vars_len is greater than
data_len before the substraction, and aborts reading the event in
that case marking the event as invalid. It also adds checks to see
that reading the server variables does not go outside the bounds
of the available space, giving a limited amount of integrity check.
2007-11-09 13:43:09 +01:00
tomas@whalegate.ndb.mysql.com
df552c310d Merge whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb
into  whalegate.ndb.mysql.com:/home/tomas/mysql-5.0-ndb-merge
2007-09-12 14:01:51 +02:00
lzhou/zhl@dev3-63.(none)
cbe2a3c780 BUG#29674 Restore/backup are endian compatible in 5.0 2007-08-07 18:07:57 +00:00
tsmith@ramayana.hindu.god
33c4cdaa66 Merge tsmith@bk-internal.mysql.com:/home/bk/mysql-5.0-build
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/50
2007-08-01 18:30:55 -06:00
kent@mysql.com/kent-amd64.(none)
519ebab04e SSL/Makefile.am mysql-test/Makefile.am:
Moved CERT files to where they are used, avoids conflict
  between two make files trying to install the same CERTs
SSL/*.pem, 
  Move: SSL/*.pem -> mysql-test/std_data/
2007-07-27 17:39:07 +02:00
dkatz@damien-katzs-computer.local
491d945ab6 Bug #29784 YaSSL assertion failure when reading 8k key.
Fixed the yassl base64 decoding to correctly allocate a maximum decoded buffer size.
2007-07-17 14:43:56 -04:00
bar@mysql.com/bar.myoffice.izhnet.ru
d3c4f1b22b Bug#28916 LDML doesn't work for utf8
and is not described in the manual
- Adding missing initialization for utf8 collations
- Minor code clean-ups: renaming variables,
  moving code into a new separate function.
- Adding test, to check that both ucs2 and utf8 user
  defined collations work (ucs2_test_ci and utf8_test_ci)
- Adding Vietnamese collation as a complex user defined
  collation example.
2007-06-07 17:55:55 +05:00
malff/marcsql@weblab.(none)
df5c5aea23 Merge weblab.(none):/home/marcsql/TREE/mysql-5.0-base
into  weblab.(none):/home/marcsql/TREE/mysql-5.0-rt-merge
2007-03-01 14:06:57 -07:00
bar@mysql.com
dd0c43d5fa Bug#15126 character_set_database is not replicated (LOAD DATA INFILE need it)
This patch fixes problem that LOAD DATA could use different
character sets when loading files on master and on slave sides:
- Adding replication of thd->variables.collation_database
- Adding optional character set clause into LOAD DATA

Note, the second way, with explicit CHARACTER SET clause
should be the recommended way to load data using an alternative
character set.
The old way, using "SET @@character_set_database=xxx" should be
gradually depricated.
2007-02-28 17:06:57 +04:00
thek@kpdesk.mysql.com
19dfc42eb6 Bug#23240 --init_file statements with NOW() reports '1970-01-01 11:00:00'as the date time
- Starting time of a query sent by bootstrapping wasn't initialized
  and starting time defaulted to 0. This later used value by NOW-
  item and was translated to 1970-01-01 11:00:00.
- Marketing the time with thd->set_time() before the call to
  mysql_parse resolves this issue.
- set_time was refactored to be part of the thd->init_for_queries-
  process.
2007-02-19 14:57:54 +01:00
gluh@mysql.com/gluh.(none)
118a0c7fe2 Merge mysql.com:/home/gluh/MySQL/Merge/5.0
into  mysql.com:/home/gluh/MySQL/Merge/5.0-opt
2006-12-12 14:01:06 +04:00
holyfoot/hf@mysql.com/deer.(none)
9e52ef1f9d Merge mysql.com:/home/hf/work/22372/my41-22372
into  mysql.com:/home/hf/work/22372/my50-22372
2006-12-06 22:02:39 +04:00
holyfoot/hf@mysql.com/deer.(none)
f404488d29 bug #22372
datafile added to be used in gis.test
2006-12-06 21:47:29 +04:00
msvensson@neptunus.(none)
4c26bf9c1d Bug#19371 VARBINARY() have trailing zeros after upgrade from 4.1
- Detect if a table has field of type MYSQL_TYPE_VAR_STRING while running
   "CHECK TABLE t FOR UPGRADE" and indicate it need to be fixed
   with "REPAIR TABLE t".
 - When running a "REPAIR TABLE t" or "ALTER TABLE t FORCE" on the above
   table, install a special copy function to trim off the trailing spaces
   which we safely can say that the pre 5.0 mysqld didn't put there.
2006-11-09 12:00:27 +01:00
msvensson@neptunus.(none)
458df10d85 Bug#21868 Server crashes if encrypted certificate key provided
- Add test case which runs the same tests as ssl.test but with a different DES encrypted key
2006-09-25 16:44:15 +02:00
kostja@bodhi.local
3bf609b7f2 A fix for Bug#14897 "ResultSet.getString("table.column") sometimes
doesn't find the column"

When a user was using 4.1 tables with VARCHAR column and 5.0 server
and a query that used a temporary table to resolve itself, the
table metadata for the varchar column sent to client was incorrect:
MYSQL_FIELD::table member was empty.

The bug was caused by implicit "upgrade" from old VARCHAR to new
VARCHAR hard-coded in Field::new_field, which did not preserve
the information about the original table. Thus, the field metadata
of the "upgraded" field pointed to an auxiliary temporary table
created for query execution.

The fix is to copy the pointer to the original table to the new field.
2006-08-30 00:38:58 +04:00
konstantin@mysql.com
b99e11c8bd A fix and a test case for Bug#17843 "Certain stored procedures fail to
run at startup"

The server returned an error when trying to execute init-file with a 
stored procedure that could return multiple result sets to the client. 
A stored procedure can return multiple result sets if it contains 
PREPARE, SELECT, SHOW and similar statements.
   
The fix is to set client_capabilites|=CLIENT_MULTI_RESULTS in
sql_parse.cc:handle_bootstrap(). There is no "client" really, so 
nothing is ever sent. This makes init-file feature behave consistently: 
the prepared statements that can be called directly in the init-file 
can be used in a stored procedure too.

Re-committed the patch originally submitted by Per-Erik after review.
2006-07-04 23:46:15 +04:00
msvensson@neptunus.(none)
91e4fd9ac9 Merge neptunus.(none):/home/msvensson/mysql/mysql-4.1
into  neptunus.(none):/home/msvensson/mysql/mysql-5.0
2006-05-29 09:06:06 +02:00
msvensson@neptunus.(none)
22ff4c2865 Bug#15328 Segmentation fault occured if my.cnf is invalid for escape sequence
- Check that length of value is longer than 1 before decrementing length by 2.
 - Backport from 5.0, make it possible to use my_print_defaults in tests
2006-05-11 14:13:14 +02:00
msvensson@neptunus.(none)
f0ac0fdf06 Add an untrusted cacert used when testing 2006-05-03 14:10:22 +02:00
anozdrin@mysql.com
e03e522201 Fix for BUG#16266: Definer is not fully qualified error during replication.
The idea of the fix is to extend support of non-SUID triggers for backward
compatibility. Formerly non-SUID triggers were appeared when "new" server
is being started against "old" database. Now, they are also created when
"new" slave receives updates from "old" master.
2006-03-01 14:13:07 +03:00
jimw@mysql.com
607c129737 Merge mysql.com:/home/jimw/my/mysql-4.1-clean
into  mysql.com:/home/jimw/my/mysql-5.0-clean
2005-10-26 14:11:08 -07:00
jimw@mysql.com
2d018862fa Merge mysql.com:/home/jimw/my/mysql-4.1-11203
into  mysql.com:/home/jimw/my/mysql-4.1-clean
2005-10-21 17:57:51 -07:00
tomas@poseidon.ndb.mysql.com
fd0cd55652 Bug #13009 No gaps allowed in node id number sequence
+ some small bugfixes in ndb_config
+ extending ndb_config to print connections and take shm option
2005-10-12 14:17:39 +02:00
jonas@perch.ndb.mysql.com
6cff2db932 ndb
Add support/test for using my.cnf [cluster_config]
2005-09-30 12:19:15 +02:00
mats@mysql.com
0449ee1ca8 Merging 4.1 into 5.0 2005-07-05 16:02:03 +02:00
mats@mysql.com
6d924c8286 Bug#11401: Setting thd->lex so that engines (i.e., InnoDB) recognizes
this as a LOAD DATA ... REPLACE INTO .. statement.
2005-07-05 13:55:54 +02:00
jimw@mysql.com
dab880274a Fix LOAD DATA to handle having the escape and enclosed-by character
be the same. (Bug #11203)
2005-06-22 16:14:14 -07:00
gbichot@quadita2.mysql.com
7b0e872695 testing repl of timezone with LOAD DATA INFILE (hourra!) 2005-03-24 16:43:50 +01:00
dlenev@brandersnatch.localdomain
f169114042 WL#874 "Extended LOAD DATA".
Now one can use user variables as target for data loaded from file
(besides table's columns). Also LOAD DATA got new SET-clause in which
one can specify values for table columns as expressions.

For example the following is possible:
LOAD DATA INFILE 'words.dat' INTO TABLE t1 (a, @b) SET c = @b + 1;

This patch also implements new way of replicating LOAD DATA.
Now we do it similarly to other queries.
We store LOAD DATA query in new Execute_load_query event
(which is last in the sequence of events representing LOAD DATA).
When we are executing this event we simply rewrite part of query which
holds name of file (we use name of temporary file) and then execute it
as usual query. In the beggining of this sequence we use Begin_load_query
event which is almost identical to Append_file event
2005-03-16 04:32:47 +03:00
serg@serg.mylan
24dcb103f3 fix rpl_trunc_binlog to test the new behaviour 2005-02-19 22:24:13 +01:00
monty@mysql.com
563500994a Update results for new varchar handling
Fixed compiler warnings
String results in CREATE ... SELECT are now created as CHAR(0), VARCHAR(X) or TEXT() depending on item->max_length
2004-12-07 15:47:00 +02:00
monty@mysql.com
9252656d49 merge with 4.0 2004-11-12 11:17:53 +02:00
dlenev@mysql.com
fa21feda93 Fix for bug #6387 "Queried timestamp values do not match the inserted
value if server runs in time zone with leap seconds".

Now in my_gmt_sec() function we take into account difference between
our target and estimation in seconds part.
2004-11-03 17:59:03 +00:00
serg@sergbook.mylan
606073084e symlink, not hardlink
mkdir in Makefile, not in configure
chmod a-x
2004-04-21 14:55:39 -05:00
monty@mysql.com
ce14578909 Merge with 4.0.18 2004-02-11 00:06:46 +01:00
lenz@mysql.com
e306876fe1 - renamed mysql-test/t/init_file.sql to mysql-test/std_data/init_file.dat
so it gets picked up by "make dist" and updated init_file test accordingly.
2004-02-05 23:36:54 +01:00
monty@mysql.com
e0cc6799ec Merge with 4.0.17 2003-12-17 17:35:34 +02:00
monty@mysql.com
d47deebb58 Extend max_allowed_packet to 2G in mysql and mysqldump (Bug #2105)
Don't dump data for MRG_ISAM or MRG_MYISAM tables. (Bug #1846)
Ensure that 'lower_case_table_names' is always set on case insensitive file systems. (Bug #1812)
One can now configure MySQL as windows service as a normal user. (Bug #1802)
Database names is now compared with lower case in ON clause when lower_case_table_names is set. (Bug #1736)
IGNORE ... LINES option didn't work when used with fixed length rows. (Bug #1704)
Change INSERT DELAYED ... SELECT... to INSERT .... SELECT (Bug #1983)
Safety fix for service 'mysql start' (Bug #1815)
2003-12-14 06:39:52 +02:00
monty@narttu.mysql.fi
d9ff665102 Fixes after merge 2003-10-08 12:01:58 +03:00
monty@narttu.mysql.fi
6056cfadfc Merge with 4.0.16 2003-10-07 15:42:26 +03:00