1. 01 Aug, 2015 1 commit
  2. 31 Jul, 2015 10 commits
  3. 29 Jul, 2015 1 commit
  4. 25 Jul, 2015 2 commits
    • Monty's avatar
      Fixed memory loss detected on P8. This can happen when we call after_flush but... · e40bc659
      Monty authored
      Fixed memory loss detected on P8. This can happen when we call after_flush but never call after_rollback() or after_commit().
      
      The old code used pthread_setspecific() to store temporary data used by the thread.
      This is not safe when used with thread pool, as the thread may change for the transaction.
      
      The fix is to save the data in THD, which is guaranteed to be properly freed.
      I also fixed the code so that we don't do a malloc() for every transaction.
      e40bc659
    • Monty's avatar
      Fixed warnings and errors found by buildbot · 71153414
      Monty authored
      field.cc
      - Fixed warning about overlapping memory copy (backport from 10.0)
      
      Item_subselect.cc
      - Fixed core dump in main.view
      - Problem was that thd->lex->current_select->master_unit()->item was not set, which caused crash in maxr_as_dependent
      
      sql/mysqld.cc
      - Got error on shutdown as we where freeing mutex before all THD objects was freed
        (~THD uses some mutex). Fixed by during shutdown freeing THD inside mutex.
      
      sql/log.cc
      - log_space_lock and LOCK_log where locked in inconsistenly. Fixed by not having a log_space_lock around purge_logs.
      
      sql/slave.cc
      - Remove unnecessary log_space_lock
      - Move cond_broadcast inside lock to ensure we don't miss the signal
      71153414
  5. 21 Jul, 2015 1 commit
    • Jan Lindström's avatar
      MDEV-8474: InnoDB sets per-connection data unsafely · 7a967021
      Jan Lindström authored
      Analysis: At check_trx_exists function InnoDB allocates
      a new trx if no trx is found from thd but this newly
      allocated trx is not registered to thd. This is unsafe,
      because nothing prevents InnoDB plugin from being uninstalled
      while there's active transaction. This can cause crashes, hang
      and any other odd behavior. It may also corrupt stack, as
      functions pointers are not available after dlclose.
      
      Fix: The fix is to use thd_set_ha_data() when
      manipulating per-connection handler data. It does appropriate
      plugin locking.
      7a967021
  6. 16 Jul, 2015 3 commits
    • Monty's avatar
      a63d8738
    • Monty's avatar
      MDEV-8432 Slave cannot replicate signed integer-type values with high bit set to 1 · 00d3b20f
      Monty authored
      The fix is that if the slave has a different integer size than
      the master, then they will assume the master has the same signed/unsigned modifier
      as the slave.
      
      This means that one can safely change a coon the slave an int to a bigint
      or an unsigned int to an unsigned int.  Changing an unsigned int to an
      signed bigint will cause replication failures when the high bit of the
      unsigned int is set.
      
      We can't give an error if the signess is different on the master and slave
      as the binary log doesn't contain the signess of the column on the master.
      00d3b20f
    • Monty's avatar
      MDEV-8432 Slave cannot replicate signed integer-type values with high bit set to 1 · 44de090a
      Monty authored
      The fix is that if the slave has a different integer size than
      the master, then they will assume the master has the same signed/unsigned modifier
      as the slave.
      
      This means that one can safely change a coon the slave an int to a bigint
      or an unsigned int to an unsigned int.  Changing an unsigned int to an
      signed bigint will cause replication failures when the high bit of the
      unsigned int is set.
      
      We can't give an error if the signess is different on the master and slave
      as the binary log doesn't contain the signess of the column on the master.
      44de090a
  7. 26 Jun, 2015 1 commit
  8. 25 Jun, 2015 4 commits
    • Monty's avatar
      Simple cleanups · 67c56ab1
      Monty authored
      - Removing use of calls to current_thd
      - More DBUG_PRINT
      - Code style changes
      - Made some local functions static
      Ensure that calls to print_keyuse are locked with mutex to get all lines in same debug packet
      67c56ab1
    • Monty's avatar
      Problem was that for cases like: · 8c815751
      Monty authored
      SELECT ... WHERE XX IN (SELECT YY)
      this was transformed to something like:
      SELECT ... WHERE IF_EXISTS(SELECT ... HAVING XX=YY)
      
      The bug was that for normal execution XX was fixed in the original outer SELECT context while in PS it was fixed in the sub query context and this confused the optimizer.
      
      Fixed by ensuring that XX is always fixed in the outer context.
      8c815751
    • Monty's avatar
      Fixed crashing bug when using ONLY_FULL_GROUP_BY in a stored procedure/trigger... · 2e941fe9
      Monty authored
      Fixed crashing bug when using ONLY_FULL_GROUP_BY in a stored procedure/trigger that is repeatedly executed.
      This is MDEV-7601, including it's sub tasks MDEV-7594, MDEV-7555, MDEV-7590, MDEV-7581, MDEV-7589
      
      The problem was that select_lex->non_agg_fields was not properly reset for re-execution and this caused an overwrite of a random memory position.
      The fix was move non_agg_fields from select_lext to JOIN, which is properly reset.
      2e941fe9
    • Balasubramanian Kandasamy's avatar
      Update docker package names · 830bcff0
      Balasubramanian Kandasamy authored
      830bcff0
  9. 22 Jun, 2015 2 commits
  10. 19 Jun, 2015 2 commits
    • Annamalai Gurusami's avatar
      Bug #20762798 FK DDL: CRASH IN DICT_FOREIGN_REMOVE_FROM_CACHE · db2ed27e
      Annamalai Gurusami authored
      Problem:
      
      If we add a referential integrity constraint with a duplicate
      name, an error occurs.  The foreign key object would not have
      been added to the dictionary cache.  In the error path, there
      is an attempt to remove this foreign key object. Since this
      object is not there, the search returns a NULL result.
      De-referencing the null object results in this crash.
      
      Solution:
      
      If the search to the foreign key object failed, then don't
      attempt to access it.
      
      rb#9309 approved by Marko.
      db2ed27e
    • V S Murthy Sidagam's avatar
      Bug #21221862 NEWEST RHEL/CENTOS OPENSSL UPDATE BREAKS MYSQL DHE CIPHERS · dbbe747e
      V S Murthy Sidagam authored
      Description: The newest RHEL/CentOS/SL 6.6 openssl package
      (1.0.1e-30.el6_6.9; published around 6/4/2015) contains a fix for
      LogJam. RedHat's fix for this was to limit the use
      of any SSL DH key sizes to a minimum of 768 bits. This breaks any
      DHE SSL ciphers for MySQL clients as soon as you install the
      openssl update, since in vio/viosslfactories.c, the default
      DHPARAM is a 512 bit one. This cannot be changed in
      configuration/runtime; and needs a recompile. Because of this the
      client connection with --ssl-cipher=DHE-RSA-AES256-SHA is not
      able to connect the server.
      
      Analysis: Openssl has changed Diffie-Hellman key from the 512 to
      1024 due to some reasons(please see the details at
      http://openssl.org/news/secadv_20150611.txt) Because of this the client
      with DHE cipher is failing to connect the server. This change took
      place from the openssl-1.0.1n onwards.
      
      Fix: Similar bug fix is already pushed to mysql-5.7 under bug#18367167.
      Hence we backported the same fix to mysql-5.5 and mysql-5.6.
      dbbe747e
  11. 17 Jun, 2015 2 commits
  12. 16 Jun, 2015 2 commits
  13. 11 Jun, 2015 3 commits
  14. 09 Jun, 2015 6 commits
    • Sergei Golubchik's avatar
      tests for MDEV-7937: Enforce SSL when --ssl client option is used · 5a44e1a4
      Sergei Golubchik authored
      * add a test when server certificate is verified successfully
      * one test with two combinations (instead of two tests)
      * verbose tets: make it print what it is doing
      * fix the test to work with yassl and no-ssl builds
      5a44e1a4
    • Sergey Vojtovich's avatar
      MDEV-3870 - Valgrind warnings on OPTIMIZE MyISAM or Aria TABLE with disabled · 80f6b225
      Sergey Vojtovich authored
                  keys
      
      Fixed that OPTIMIZE TABLE against MyISAM/Aria table may write uninitialized key
      root position for disabled keys.
      80f6b225
    • Sergey Vojtovich's avatar
      MDEV-363 - Server crashes in intern_plugin_lock on concurrent installing · 3a50a8c9
      Sergey Vojtovich authored
                 semisync plugin and setting rpl_semi_sync_master_enabled
      
      There was race condition between INSTALL PLUGIN and SET. It was caused by a
      gap in INSTALL PLUGIN when plugin variables were registered but not fully
      initialized. Accessing such variables concurrently may reference uninitialized
      memory, specifically sys_var_pluginvar::plugin.
      
      Fixed by initializing sys_var_pluginvar::plugin early, before variable is
      registered.
      3a50a8c9
    • Sergey Vojtovich's avatar
      MDEV-363 - Server crashes in intern_plugin_lock on concurrent installing · 49a33924
      Sergey Vojtovich authored
                 semisync plugin and setting rpl_semi_sync_master_enabled
      
      Cleanup:
      Removed my_intern_plugin_lock() and my_intern_plugin_lock_ci() wrappers. They
      were obsoleted by revision f56dd32b.
      49a33924
    • Sergei Golubchik's avatar
      disable ssl for ssl-disabled tests · e5005ced
      Sergei Golubchik authored
      instead of running them only when ssl is not compiled in
      e5005ced
    • Sergei Petrunia's avatar
      MDEV-6735: Range checked for each record used with key (also MDEV-7786, MDEV-7923) · 992d782d
      Sergei Petrunia authored
      "Range Checked for Each Record" should be only employed when the other
      option would be cross-product join (i.e. the other option is so bad that
      we hardly risk anything).
      
      Previous logic was: use RCfER if there are no possible quick selects, or
      quick select would read > 100 rows. Also, it didn't always work as
      expected due to range optimizer changing table->quick_keys and us
      looking at sel->quick_keys.
      
      Another angle is that recent versions have enabled use of Join Buffering
      in e.g. outer joins. This further reduces the range of cases where RCfER
      should be used.
      
      We are still unable to estimate the cost of RCfER with any precision, so
      now changing the condition of "no quick select or quick->records> 100"
      to a hopefully better condition "no quick select or quick would cost more
      than full table scan".
      992d782d