Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-35401

Dead code: save_prep_leaf_tables() functions and leaf_tables_prep

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 11.2
    • 11.2
    • Optimizer
    • None

    Description

      After this patch:

      commit 3a9358a4106a1bd0ae2414f6f0bda50afdd65f0a 
      Author: Igor Babaev <igor@askmonty.org>
      Date:   Sat Jun 18 16:28:48 2022 -0700
       
          MDEV-28883 Re-design the upper level of handling UPDATE and DELETE statements
      

      The functions

      bool st_select_lex::save_prep_leaf_tables(THD *thd)
      bool LEX::save_prep_leaf_tables()
      

      are never called, and these members are never set to anything except the their inital state:

      class st_select_lex
      {
        ...
        List<TABLE_LIST> leaf_tables_prep;
        enum leaf_list_state prep_leaf_list_state;
      

      setup_tables() still has [dead] code that checks prep_leaf_list_state.

      When I remove all of the above (patch attached), mtr still passes.

      Attachments

        Activity

          People

            Unassigned Unassigned
            psergei Sergei Petrunia
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.