1. 15 Jun, 2010 2 commits
  2. 14 Jun, 2010 2 commits
  3. 12 Jun, 2010 1 commit
  4. 11 Jun, 2010 4 commits
    • Alexey Kopytov's avatar
      Automerge. · 08f3b0ab
      Alexey Kopytov authored
      08f3b0ab
    • Ramil Kalimullin's avatar
      Automerge. · d4746b8e
      Ramil Kalimullin authored
      d4746b8e
    • Alexey Kopytov's avatar
      Manual merge from the bugfix tree. · 162e4262
      Alexey Kopytov authored
      conflicts:
         conflict      sql/sql_parse.cc
      162e4262
    • Martin Hansson's avatar
      Bug#53859: Valgrind: opt_sum_query(TABLE_LIST*, List<Item>&, · 5bace3f0
      Martin Hansson authored
      Item*) at opt_sum.cc:305
            
      Queries applying MIN/MAX functions to indexed columns are
      optimized to read directly from the index if all key parts
      of the index preceding the aggregated key part are bound to
      constants by the WHERE clause. A prefix length is also
      produced, equal to the total length of the bound key
      parts. If the aggregated column itself is bound to a
      constant, however, it is also included in the prefix.
      
      Such full search keys are read as closed intervals for
      reasons beyond the scope of this bug. However, the procedure
      missed one case where a key part meant for use as range
      endpoint was being overwritten with a NULL value destined
      for equality checking. In this case the key part was
      overwritten but the range flag remained, causing open
      interval reading to be performed.
      
      Bug was fixed by adding more stringent checking to the
      search key building procedure (matching_cond) and never
      allow overwrites of range predicates with non-range
      predicates.
      
      An assertion was added to make sure open intervals are never
      used with full search keys.
      5bace3f0
  5. 10 Jun, 2010 5 commits
    • Davi Arnaut's avatar
      Bug#42733: Type-punning warnings when compiling MySQL -- · 53b88296
      Davi Arnaut authored
                  strict aliasing violations.
      
      One somewhat major source of strict-aliasing violations and
      related warnings is the SQL_LIST structure. For example,
      consider its member function `link_in_list` which takes
      a pointer to pointer of type T (any type) as a pointer to
      pointer to unsigned char. Dereferencing this pointer, which
      is done to reset the next field, violates strict-aliasing
      rules and might cause problems for surrounding code that
      uses the next field of the object being added to the list.
      
      The solution is to use templates to parametrize the SQL_LIST
      structure in order to deference the pointers with compatible
      types. As a side bonus, it becomes possible to remove quite
      a few casts related to acessing data members of SQL_LIST.
      53b88296
    • Davi Arnaut's avatar
      Bug#42733: Type-punning warnings when compiling MySQL -- · bb036c93
      Davi Arnaut authored
                 strict aliasing violations.
      
      Essentially, the problem is that large parts of the server were
      developed in simpler times (last decades, pre C99 standard) when
      strict aliasing and compilers supporting such optimizations were
      rare to non-existent. Thus, when compiling the server with a modern
      compiler that uses strict aliasing rules to perform optimizations,
      there are several places in the code that might trigger undefined
      behavior.
      
      As evinced by some recent bugs, GCC does a somewhat good of job
      misoptimizing such code, but on the other hand also gives warnings
      about suspicious code. One problem is that the warnings aren't
      always accurate, yet we can't afford to just shut them off as we
      might miss real cases. False-positive cases are aggravated mostly
      by casts that are likely to trigger undefined behavior.
      
      The solution is to start a cleanup process focused on fixing and
      reducing the amount of strict-aliasing related warnings produced
      by GCC and others compilers. A good deal of noise reduction can
      be achieved by just removing useless casts that are product of
      historical cruft and are likely to trigger undefined behavior if
      dereferenced.
      bb036c93
    • Tor Didriksen's avatar
      Backport of Bug#53303 mytap tests should always have a plan() · e3b4d331
      Tor Didriksen authored
      The bug was caused by buffered output. Flushing resolved it.
      We still recommend to allways call plan().
        
      Also fix some compile warnings (formal parameter different from declaration)
      e3b4d331
    • Davi Arnaut's avatar
      2c8fd5fa
    • Davi Arnaut's avatar
      Bug#34236: Various possibly related SSL crashes · b564aa92
      Davi Arnaut authored
      Addendum: Work around a compilation failure on Windows due to
                windows.h not being added to the global namespace.
      b564aa92
  6. 09 Jun, 2010 2 commits
  7. 08 Jun, 2010 7 commits
  8. 07 Jun, 2010 2 commits
  9. 04 Jun, 2010 5 commits
  10. 03 Jun, 2010 4 commits
  11. 02 Jun, 2010 5 commits
    • Luis Soares's avatar
    • Luis Soares's avatar
      BUG#53893: RBR: nullable unique key can lead to out-of-sync slave · 8ce9f9b3
      Luis Soares authored
      When using Unique Keys with nullable parts in RBR, the slave can
      choose the wrong row to update. This happens because a table with
      an unique key containing nullable parts cannot strictly guarantee 
      uniqueness. As stated in the manual, for all engines, a UNIQUE 
      index allows multiple NULL values for columns that can contain 
      NULL.
      
      We fix this at the slave by extending the checks before assuming
      that the row found through an unique index is is the correct
      one. This means that when a record (R) is fetched from the storage
      engine and a key that is not primary (K) is used, the server does 
      the following: 
      
       - If K is unique and has no nullable parts, it returns R;
       - Otherwise, if any field in the before image that is part of K
         is null do an index scan;
       - If there is no NULL field in the BI part of K, then return R.
      
      A side change: renamed the existing test case file and added a
      test case covering the changes in this patch.
      8ce9f9b3
    • Luis Soares's avatar
      21634b92
    • Luis Soares's avatar
      BUG#54161: MTR: disabled.def lists don't work with FQ test names · 2a8a7395
      Luis Soares authored
      MTR will ignore fully qualified test name entries in disabled.def 
      lists. Therefore, it would still run the test case, even if it is
      listed.
      
      This patch fix this by extending the check when marking the test
      case as disabled to take into consideration not only the cases that
      contain the simple test name but also those that contain fully 
      qualified test names.
      2a8a7395
    • Alexey Kopytov's avatar
      Automerge. · 36d27699
      Alexey Kopytov authored
      36d27699
  12. 01 Jun, 2010 1 commit