1. 14 May, 2009 1 commit
    • Philip Stoev's avatar
      Bugs #44871 and #43894: · e67233ff
      Philip Stoev authored
      UNIX sockets need to be on a path shorter than 70 characters on some older platofrms.
      MTRv1 tries to fix this by moving the socket to the $TMPDIR, however this causes
      issues with certain tests on Windows.
      
      Fixed by not applying any hacks on Windows - Windows does not need them.
      e67233ff
  2. 13 May, 2009 1 commit
  3. 12 May, 2009 2 commits
    • Jim Winstead's avatar
      Merge from 5.0-bugteam · c65ebb5d
      Jim Winstead authored
      c65ebb5d
    • Ramil Kalimullin's avatar
      Fix for bug#44774: load_file function produces valgrind warnings · 8b9084ef
      Ramil Kalimullin authored
      Problem: using LOAD_FILE() in some cases we pass a file name string
      without a trailing '\0' to fn_format() which relies on that however.
      That may lead to valgrind warnings.
      
      Fix: add a trailing '\0' to the file name passed to fn_format().
      
      
      mysql-test/r/func_str.result:
        Fix for bug#44774: load_file function produces valgrind warnings
          - test result.
      mysql-test/t/func_str.test:
        Fix for bug#44774: load_file function produces valgrind warnings
          - test case.
      sql/item_strfunc.cc:
        Fix for bug#44774: load_file function produces valgrind warnings
          - passing a file name to fn_format(), file_name->c_ptr() replaced
            with file_name->c_ptr_safe() to ensure we have a trailing '\0'.
      8b9084ef
  4. 10 May, 2009 1 commit
    • Ramil Kalimullin's avatar
      Fix for bug#42009: SELECT into variable gives different results to direct SELECT · d615a11b
      Ramil Kalimullin authored
      Problem: storing "SELECT ... INTO @var ..." results in variables we used val_xxx()
      methods which returned results of the current row. 
      So, in some cases (e.g. SELECT DISTINCT, GROUP BY or HAVING) we got data
      from the first row of a new group (where we evaluate a clause) instead of
      data from the last row of the previous group.
      
      Fix: use val_xxx_result() counterparts to get proper results.
      
      
      mysql-test/r/distinct.result:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - results adjusted.
      mysql-test/r/user_var.result:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - test result.
      mysql-test/t/user_var.test:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - test case.
      sql/item_func.cc:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - Item_func_set_user_var::save_item_result() added to evaluate and store 
            an item's result into a user variable.
      sql/item_func.h:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - Item_func_set_user_var::save_item_result() added to evaluate and store 
            an item's result into a user variable.
      sql/sql_class.cc:
        Fix for bug#42009: SELECT into variable gives different results to direct SELECT
          - use Item_func_set_user_var::save_item_result() to store results into user 
            variables.
      d615a11b
  5. 08 May, 2009 2 commits
  6. 07 May, 2009 4 commits
    • Jim Winstead's avatar
      The get_date() function in mysys interpreted the GETDATE_GMT option · df3887f9
      Jim Winstead authored
      backwards, which resulted in the incorrect time being reported at the
      end of mysqldump. (Bug #44424, patch by Andrew Hutchings)
      df3887f9
    • Jim Winstead's avatar
      Fix support for -i (--ignore-spaces) in the mysql command line application, · 3fe1d299
      Jim Winstead authored
      which didn't actually do anything. (Bug #39101)
      3fe1d299
    • Alexey Kopytov's avatar
      Bug #41943: mysqlbinlog.exe crashes if --hexdump option is used · c0cd2742
      Alexey Kopytov authored
        
      The --hexdump option crashed mysqlbinlog when used together  
      with the --read-from-remote-server option due to use of  
      uninitialized memory.  
        
      Since Log_event::print_header() relies on temp_buf to be  
      initialized when the --hexdump option is present,  
      dump_remote_log_entries() was fixed to setup temp_buf to point  
      to the start of a binlog event as done in  
      dump_local_log_entries().  
       
      The root cause of this bug is identical to the one for 
      bug #17654. The latter was fixed in 5.1 and up, so this 
      patch is backport of the patches for bug #17654 to 5.0. 
       
      Only 5.0 needs a changelog entry. 
      
      client/mysqlbinlog.cc:
        Fixed dump_remote_log_entries() so that temp_buf is initialized 
        as it may be used later by Log_event::print_header() if the 
        --hexdump option is present.
      mysql-test/r/mysqlbinlog.result:
        Added a test case for bug #41943.
      mysql-test/t/mysqlbinlog.test:
        Added a test case for bug #41943.
      c0cd2742
    • Bernt M. Johnsen's avatar
      a9f57db0
  7. 06 May, 2009 2 commits
    • Anurag Shekhar's avatar
      merging with local fix. · 69fcfa67
      Anurag Shekhar authored
      69fcfa67
    • Anurag Shekhar's avatar
      Bug #39918 memory (heap) engine crashing with b-tree index and DELETE · 609a794b
      Anurag Shekhar authored
               with seg fault
      
      Multiple-table DELETE from a table joined to itself may cause
      server crash. This was originally discovered with MEMORY engine,
      but may affect other engines with different symptoms.
      
      The problem was that the server violated SE API by performing
      parallel table scan in one handler and removing records in
      another (delete on the fly optimization).
      
      
      mysql-test/r/heap_btree.result:
        Updated test result after adding new test for this bug.
      mysql-test/t/heap_btree.test:
        Updated test result after adding new test for the bug report.
      sql/sql_delete.cc:
        Updated to check if the files in delete list appears in join list and disable 
        delete while scanning, if it appears.
      609a794b
  8. 05 May, 2009 1 commit
  9. 30 Apr, 2009 6 commits
  10. 29 Apr, 2009 1 commit
  11. 28 Apr, 2009 7 commits
    • Matthias Leich's avatar
      Merge latest changes into local GCA tree · ae154dca
      Matthias Leich authored
      no conflicts
      ae154dca
    • Matthias Leich's avatar
      Fix for Bug#43546 Several 5.0 tests do not pass MTR's --check option · 2328f9b1
      Matthias Leich authored
                        (moved from Bug 42308)
      
      Details:
      - insert_update
        Add DROP TABLE which was missing, error numbers -> names
      - varbinary
        Add DROP TABLE which was missing
      - sp_trans_log
        Add missing DROP function, improved formatting
      2328f9b1
    • Staale Smedseng's avatar
      Bug#35769 typo in mysqlhotcopy documentation · 9f04d270
      Staale Smedseng authored
            
      Fixed a number of typos, and made punctuation and
      capitalization more consistent in documentation
      and help.
      9f04d270
    • Andrei Elkin's avatar
      Bug #38694 Race condition in replication thread shutdown · d38e6263
      Andrei Elkin authored
      The issue of the current bug is unguarded access to mi->slave_running 
      by the shutdown thread calling end_slave() that is bug#29968 
      (alas happened not to be cross-linked with the current bug)
      
      Fixed:
      
      with removing the unguarded read of the running status
      and perform reading it in terminate_slave_thread()
      at time run_lock is taken (mostly bug#29968 backporting, still with some
      improvements over that patch - see the error reporting from 
      terminate_slave_thread()).
      Issue of bug#38716 is fixed here for 5.0 branch as well.
      
      Note:
      
      There has been a separate artifact identified - 
      a race condition between init_slave() and  end_slave() - 
      reported as  Bug#44467.
      
      mysql-test/r/rpl_bug38694.result:
        a new results file is added.
      mysql-test/t/rpl_bug38694-slave.opt:
        simulating delay at slave threads shutdown.
      mysql-test/t/rpl_bug38694.test:
        A new test to check if a delay at the termination phase of slave threads
        could cause any issue.
      sql/slave.cc:
        The unguarded read of the running status is removed. Its reading is done in
        terminate_slave_thread() at time run_lock is taken;
        Calling terminate_slave_threads(skip_lock := !need_slave_mutex) in the failing branch of start_slave_threads() which is bug#38716 issue.
      sql/slave.h:
        removing terminate_slave_thread() out of the global interface scope.
      d38e6263
    • Alexey Botchkov's avatar
      merging · ddc9a195
      Alexey Botchkov authored
      ddc9a195
    • Alexey Botchkov's avatar
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash · 620fb880
      Alexey Botchkov authored
         the Point() and Linestring() functions create WKB representation of an
         object instead of an real geometry object.
         That produced bugs when these were inserted into tables.
      
         GIS tests fixed accordingly.
                  
      per-file messages:
        mysql-test/r/gis-rtree.result
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash 
          test result
        mysql-test/r/gis.result
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash 
          test result
        mysql-test/t/gis-rtree.test
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash 
          test fixed - GeomFromWKB invocations removed
        mysql-test/t/gis.test
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash 
          test fixed - AsWKB invocations added
        sql/item_geofunc.cc
      Bug#38990 Arbitrary data input plus GIS functions causes mysql server crash 
           Point() and similar functions to create a proper object
      620fb880
    • Gleb Shchepa's avatar
      backport from 6.0: · def04705
      Gleb Shchepa authored
      Bug #40925: Equality propagation takes non indexed attribute
      
      Query execution plans and execution time of queries like
      
        select a, b, c from t1
          where a > '2008-11-21' and b = a limit 10
      
      depended on the order of equality operator parameters:
      "b = a" and "a = b" are not same. 
      
      
      An equality propagation algorithm has been fixed:
      the substitute_for_best_equal_field function should not
      substitute a field for an equal field if both fields belong
      to the same table.
      
      
      mysql-test/r/select.result:
        Added test case for bug #40925.
      mysql-test/t/select.test:
        Added test case for bug #40925.
      sql/item.cc:
        Bug #40925: Equality propagation takes non indexed attribute
        
        An equality propagation algorithm has been fixed:
        the substitute_for_best_equal_field function should not 
        substitute a field for an equal field if both fields belong
        to the same table.
      def04705
  12. 24 Apr, 2009 5 commits
  13. 23 Apr, 2009 1 commit
  14. 21 Apr, 2009 1 commit
    • Sergey Vojtovich's avatar
      BUG#36966 - mysqldump.test fails in pushbuild · f8b219ee
      Sergey Vojtovich authored
      mysqldump.test is designed to run with concurrent inserts
      disabled. It is disabling concurrent inserts at the very
      beginning of the test case, and re-enables them at the
      bottom of the test. But for some reason (likely incorrect
      merge) we enable concurrent inserts in the middle of the test.
      
      The problem is fixed by enabling concurrent inserts only
      at the bottom of the test case.
      f8b219ee
  15. 17 Apr, 2009 2 commits
    • Georgi Kodinov's avatar
      Bug #35087: Inserting duplicate values at one time with DES_ENCRYPT leads · 08044795
      Georgi Kodinov authored
        to wrong results
            
      3 problems found with DES_ENCRYPT/DES_DECRYPT :
      
      1. The max length was not calculated properly. Fixed in fix_length_and_dec()
      2. DES_ENCRYPT had a side effect of sometimes reallocating and changing 
      the value of its argument. Fixed by explicitly pre-allocating the necessary
      space to pad the argument with trailing '*' (stars) when calculating the 
      DES digest.
      3. in DES_ENCRYPT the string buffer for the result value was not 
      reallocated to the correct size and only string length was assigned to it. 
      Fixed by making sure there's enough space to hold the result.
      08044795
    • Sergey Glukhov's avatar
      Bug#44151 using handler commands on information_schema tables crashes server · ff923cc8
      Sergey Glukhov authored
      information schema tables are based on internal tmp tables which are removed
      after each statement execution. So HANDLER comands can not be used with
      information schema.
      
      
      mysql-test/r/handler.result:
        test result
      mysql-test/t/handler.test:
        test case
      sql/sql_handler.cc:
        information schema tables are based on internal tmp tables which are removed
        after each statement execution. So HANDLER comands can not be used with
        information schema.
      ff923cc8
  16. 16 Apr, 2009 3 commits