1. 07 Aug, 2020 1 commit
  2. 06 Aug, 2020 1 commit
    • Varun Gupta's avatar
      MDEV-15180: server crashed with NTH_VALUE() · caa474f8
      Varun Gupta authored
      fix_fields for the arguments of the NTH_VALUE function was updating the same reference,
      so for the second argument (or after the first argument) the items were not resolved
      to their corresponding field from the view as they were updating the reference to the
      first argument.
      caa474f8
  3. 05 Aug, 2020 1 commit
    • Varun Gupta's avatar
      MDEV-17066: Bytes lost or Assertion `status_var.local_memory_used == 0 after... · 1e31d748
      Varun Gupta authored
      MDEV-17066: Bytes lost or Assertion `status_var.local_memory_used == 0 after DELETE with subquery with ROLLUP
      
      The issue here is when records are read from the temporary file
      (filesort result in this case) via a cache(rr_from_cache).
      The cache is initialized with init_rr_cache.
      For correlated subquery the cache allocation is happening at each execution
      of the subquery but the deallocation happens only once and that was
      when the query execution was done.
      
      So generally for subqueries we do two types of cleanup
      
      1) Full cleanup: we should free all resources of the query(like temp tables).
         This is done generally when the query execution is complete or the subquery
         re-execution is not needed (case with uncorrelated subquery)
      
      2) Partial cleanup: Minor cleanup that is required if
         the subquery needs recalculation. This is done for all the structures that
         need to be allocated for each execution (example SORT_INFO for filesort
         is allocated for each execution of the correlated subquery).
      
      The fix here would be free the cache used by rr_from_cache in the partial
      cleanup phase.
      1e31d748
  4. 04 Aug, 2020 4 commits
    • Marko Mäkelä's avatar
      MDEV-23101 fixup: Remove redundant code · 91caf130
      Marko Mäkelä authored
      lock_rec_has_to_wait_in_queue(): Remove an obviously redundant assertion
      that was added in commit a8ec4586
      and also enclose a Galera-specific condition in #ifdef WITH_WSREP.
      91caf130
    • Rucha Deodhar's avatar
      MDEV-23082: ER_TABLEACCESS_DENIED_ERROR error message is truncated, · 5fb07d22
      Rucha Deodhar authored
      and inaccurately
      
      Analysis: The list of all privileges is 118 characters wide. However, the
      format of error message was: "%-.32s command denied to user...". get_length()
      sets the maximum width to 32 characters. As a result, only first 32
      characters of list of privilege are stored.
      Fix: Changing the format to "%-.100T..." so that get_length() sets width to
      100. Hence, first 100 characters of the list of privilege are stored and the
      type specifier 'T' appends '...' so that truncation can be seen.
      5fb07d22
    • Rucha Deodhar's avatar
      MDEV-14836: Assertion `m_status == DA_ERROR' failed in · 745fa255
      Rucha Deodhar authored
      Diagnostics_area::sql_errno upon query from I_S with LIMIT ROWS EXAMINED
      
      open_normal_and_derived_table() fails because the query was already killed
      as rows examined by the query are more than the limit. However, this isn't a
      real error.
      Fix: Check if there is actually an error before calling thd->sql_errno()
      and later send a warning in handle_select() if no real error.
      745fa255
    • Jan Lindström's avatar
      87b1625b
  5. 03 Aug, 2020 2 commits
  6. 02 Aug, 2020 7 commits
  7. 31 Jul, 2020 6 commits
    • Thirunarayanan Balathandayuthapani's avatar
      MDEV-14711 Fix-up · 5ec40fbb
      Thirunarayanan Balathandayuthapani authored
      5ec40fbb
    • Thirunarayanan Balathandayuthapani's avatar
      MDEV-22511 innodb.truncate_foreign failed in buildbot with wrong error code · a6066e23
      Thirunarayanan Balathandayuthapani authored
      - Adding lock_wait_timeout value as 1 make sure that truncate table
      fails instead of making MDL timeout.
      a6066e23
    • Marko Mäkelä's avatar
      MDEV-11799 Doublewrite recovery can corrupt data pages · 879ba197
      Marko Mäkelä authored
      The purpose of the InnoDB doublewrite buffer is to make InnoDB
      tolerant against cases where the server was killed in the middle
      of a page write. (In Linux, killing a process may interrupt a
      write system call, typically on a 4096-byte boundary.)
      
      There may exist multiple copies of a page number in the doublewrite
      buffer. Recovery should choose the latest valid copy of the page.
      By design, the FIL_PAGE_LSN must not precede the latest checkpoint LSN
      nor be later than the end of the recovered log.
      
      For page_compressed and encrypted pages, we were missing proper
      consistency checks. In the 10.4 data set generated for in MDEV-23231,
      the data file contained a valid page_compressed page, and an
      identical copy of that page was also present in the doublewrite
      buffer. But, recovery would incorrectly consider the page invalid
      and restore an uncompressed copy of the same page that had been
      written before the log checkpoint. (In fact, no redo log was to
      be applied to that page.)
      
      buf_dblwr_process(): Validate the FIL_PAGE_LSN in the doublewrite
      buffer pages, and always skip page 0, because those pages should
      have been recovered by Datafile::restore_from_doublewrite() if
      necessary.
      
      Datafile::restore_from_doublewrite(): Choose the latest applicable
      page from the doublewrite buffer.
      
      recv_dblwr_t::find_page(): Also validate encrypted or
      page_compressed pages.
      
      recv_dblwr_t::validate_page(): New function to validate a page,
      either a copy in a data file or in the doublewrite buffer.
      Also validate encrypted or page_compressed pages.
      
      This is joint work with Thirunarayanan Balathandayuthapani.
      879ba197
    • Marko Mäkelä's avatar
      MDEV-23198 Crash in REPLACE · f35d1721
      Marko Mäkelä authored
      row_vers_impl_x_locked_low(): clust_offsets may point to memory
      that is allocated by mem_heap_alloc() and may have been freed.
      For initializing clust_offsets, try to use the stack-allocated
      buffer instead of a pointer that may point to freed memory.
      
      This fixes a regression that was introduced in
      commit f0aa073f (MDEV-20950).
      f35d1721
    • Nikita Malyavin's avatar
      MDEV-18042 Server crashes upon adding a non-null date column under... · fd0abc89
      Nikita Malyavin authored
      MDEV-18042 Server crashes upon adding a non-null date column under NO_ZERO_DATE with ALGORITHM=INPLACE
      
      accept table_name and db_name instead of table_share in make_truncated_value_warning
      fd0abc89
    • Nikita Malyavin's avatar
      MDEV-19338 InnoDB: Failing assertion: !cursor->index->is_committed() · 91ebf184
      Nikita Malyavin authored
      Call mark_columns_per_binlog_row_image before find_row() to set up table->vcol_set early,
      so the virtual column value will be updated after record read (ha_rnd_pos/ha_index_next/etc)
      by table->update_virtual_fields() call
      91ebf184
  8. 30 Jul, 2020 5 commits
  9. 29 Jul, 2020 9 commits
  10. 28 Jul, 2020 4 commits