1. 26 Aug, 2010 3 commits
    • Alexey Kopytov's avatar
      Automerge. · d63b9feb
      Alexey Kopytov authored
      d63b9feb
    • Alexey Kopytov's avatar
      Automerge. · 8a310d69
      Alexey Kopytov authored
      8a310d69
    • Alexey Kopytov's avatar
      Bug #53544: Server hangs during JOIN query in stored procedure · 6c6a3e8f
      Alexey Kopytov authored
                  called twice in a row
      
      Queries with nested joins could cause an infinite loop in the
      server when used from SP/PS.
      
      When flattening nested joins, simplify_joins() tracks if the
      name resolution list needs to be updated by setting
      fix_name_res to TRUE if the current loop iteration has done any
      transformations to the join table list. The problem was that
      the flag was not reset before the next loop iteration leading
      to unnecessary "fixing" of the name resolution list which in
      turn could lead to a loop (i.e. circularly-linked part) in that
      list. This was causing problems on subsequent execution when
      used together with stored procedures or prepared statements.
      
      Fixed by making sure fix_name_res is reset on every loop
      iteration.
      6c6a3e8f
  2. 24 Aug, 2010 2 commits
    • Alexey Kopytov's avatar
      Automerge. · 947c7f30
      Alexey Kopytov authored
      947c7f30
    • Alexey Kopytov's avatar
      Bug #55568: user variable assignments crash server when used · 0e74ac50
      Alexey Kopytov authored
                  within query
      
      The server could crash after materializing a derived table
      which requires a temporary table for grouping.
      
      When destroying the temporary table used to execute a query for
      a derived table, JOIN::destroy() did not clean up Item_fields
      pointing to fields in the temporary table. This led to
      dereferencing a dangling pointer when printing out the items
      tree later in the outer SELECT.
      
      The solution is an addendum to the patch for bug37362: in
      addition to cleaning up items in tmp_all_fields3, do the same
      for items in tmp_all_fields1, since now we have an example
      where this is necessary.
      0e74ac50
  3. 20 Aug, 2010 12 commits
  4. 19 Aug, 2010 4 commits
  5. 18 Aug, 2010 2 commits
    • 's avatar
      The patch is 5.1 part of the worklog. It is for 5.1 only. · b37c8a7a
      authored
      So null merge.
      b37c8a7a
    • 's avatar
      WL#5370 Keep forward-compatibility when changing · b766a51f
      authored
              'CREATE TABLE IF NOT EXISTS ... SELECT' behaviour
      BUG#55474, BUG#55499, BUG#55598, BUG#55616 and BUG#55777 are fixed
      in this patch too.
      
      This is the 5.1 part.
      It implements:
      - if the table exists, binlog two events: CREATE TABLE IF NOT EXISTS
        and INSERT ... SELECT
      
      - Insert nothing and binlog nothing on master if the existing object
        is a view. It only generates a warning that table already exists.
      b766a51f
  6. 17 Aug, 2010 1 commit
  7. 16 Aug, 2010 6 commits
    • Georgi Kodinov's avatar
      merge · 5f211511
      Georgi Kodinov authored
      5f211511
    • Alexander Nozdrin's avatar
      Auto-merge from mysql-5.5. · 9c41a990
      Alexander Nozdrin authored
      9c41a990
    • Alexander Nozdrin's avatar
      Auto-merge from mysql-5.5-stage. · 2585da55
      Alexander Nozdrin authored
      2585da55
    • Sunny Bains's avatar
      Merge from -c3476 mysql-5.1-security. · 97aa1215
      Sunny Bains authored
           ------------------------------------------------------------
           revno: 3476
           committer: Sunny Bains <Sunny.Bains@Oracle.Com>
           branch nick: 5.1-security
           timestamp: Thu 2010-08-05 19:18:17 +1000
           message:
             Fix bug# 55543 - InnoDB Plugin: Signal 6: Assertion failure in file fil/fil0fil.c line 4306
      
               The bug is due to a double delete of a BLOB, once via:
      
                     rollback -> btr_cur_pessimistic_delete()
      
               and the second time via purge.
      
               The bug is in row_upd_clust_rec_by_insert(). There we relinquish ownership
               of the non-updated BLOB columns in btr_cur_mark_extern_inherited_fields()
               before building the row entry that will be inserted and whose contents will
               be logged in the UNDO log. However, we don't set the BLOB column later to
               INHERITED so that a possible rollback will not free the original row's
               non-updated BLOB entries. This is because the condition that checks for
               that is in :
      
           		    	if (node->upd_ext) {}.
      
               node->upd_ext is non-NULL only if a BLOB column was updated and that column
               is part of some key ordering (see row_upd_replace()). This results in the
               non-update BLOB columns being deleted during a rollback and subsequently by
               purge again.
      
               rb://413
      97aa1215
    • Sunny Bains's avatar
      Fix Bug #55277 - Failing assertion: auto_inc > 0 · 787f0c54
      Sunny Bains authored
      Handle overflow when reading value from SELECT MAX(C) FROM T;
      
      Call ha_innobase::info() after initializing the autoinc value
      in ha_innobase::open().
      
      Fix for both the builtin and plugin.
      
      rb://402
      
      Merge from mysql-5.1-security.
      787f0c54
    • Sunny Bains's avatar
      62aa8943
  8. 15 Aug, 2010 1 commit
  9. 13 Aug, 2010 8 commits
    • Georgi Kodinov's avatar
      Bug #55565: debug assertion when ordering by expressions with user · b6e3adf1
      Georgi Kodinov authored
      variable assignments
      
      The assert() that is firing is checking if expressions that can't be
      null return a NULL when evaluated.
      MAKEDATE() function can return NULL if the second argument is 
      less then or equal to 0. Thus its nullability depends not only on 
      the nullability of its arguments but also on their values.
      Fixed by (overoptimistically) setting MAKEDATE() to be nullable 
      despite the nullability of its arguments.
      Test added.
      Had to update one test result to reflect the metadata change.
      b6e3adf1
    • Vasil Dimov's avatar
      Manually merge a changeset from mysql-5.1-security: · bfca4bb9
      Vasil Dimov authored
        ------------------------------------------------------------
        revno: 3475
        revision-id: jimmy.yang@oracle.com-20100804103744-vbpeghipkz6pyc9z
        parent: jimmy.yang@oracle.com-20100804101133-c38qqbm0fkwn9jhc
        committer: Jimmy Yang <jimmy.yang@oracle.com>
        branch nick: mysql-5.1-security
        timestamp: Wed 2010-08-04 03:37:44 -0700
        message:
          Fix bug #54678, InnoDB, TRUNCATE, ALTER, I_S SELECT, crash or deadlock
          
          rb://399 approved by Sunny Bains
        modified:
          storage/innodb_plugin/ChangeLog 2425@16c675df-0fcb-4bc9-8058-dcc011a37293:branches%2Fzip%2FChangeLog
          storage/innodb_plugin/include/dict0dict.h 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Finclude%2Fdict0dict.h
          storage/innodb_plugin/include/dict0dict.ic 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Finclude%2Fdict0dict.ic
          storage/innodb_plugin/row/row0mysql.c 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Frow%2Frow0mysql.c
      bfca4bb9
    • Vasil Dimov's avatar
      Merge mysql-5.1-security -> mysql-5.5-security up to · 865210f9
      Vasil Dimov authored
      sunny.bains@oracle.com-20100805092434-tvxxzjgqgslo14en
      
      This is a null merge of InnoDB changes which will be ported into a
      separate commits.
      865210f9
    • Vasil Dimov's avatar
      Merge mysql-5.1-security -> mysql-5.5-security up to c3473 · 6a4ec43b
      Vasil Dimov authored
      (this is a null merge)
      6a4ec43b
    • Georgi Kodinov's avatar
      merge · 2ecc81cb
      Georgi Kodinov authored
      2ecc81cb
    • Georgi Kodinov's avatar
      Bug #55615 and bug #55564 · a5575096
      Georgi Kodinov authored
      An user assignment variable expression that's 
      evaluated in a logical expression context 
      (Item::val_bool()) can be pre-calculated in a 
      temporary table for GROUP BY.
      However when the expression value is used after the
      temp table creation it was re-evaluated instead of
      being read from the temp table due to a missing 
      val_bool_result() method.
      Fixed by implementing the method.
      a5575096
    • Alexander Nozdrin's avatar
      Disable test cases due to Bug 55966. · 496e1fb4
      Alexander Nozdrin authored
      496e1fb4
    • Georgi Kodinov's avatar
      Bug #55580 : segfault in read_view_sees_trx_id · 12f7d57d
      Georgi Kodinov authored
      The server was not checking for errors generated during
      the execution of Item::val_xxx() methods when copying
      data to the group, order, or distinct temp table's row.
      Fixed by extending the copy_funcs() to return an error
      code and by checking for that error code on the places
      copy_funcs() is called. 
      Test case added.
      12f7d57d
  10. 12 Aug, 2010 1 commit