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

Cleanup error handling in ha_federatedx

Details

    Description

      1. Class ha_federatedx_derived_handler overrides virtual function derived_handler::print_error() with an empty implementation which causes problems with error handling. Errors are being simply ignored and occur during later processing.

      void ha_federatedx_derived_handler::print_error(int, unsigned long)
      {
      }
      

      2. Members of federatedx_handler_base are accessed in the end_scan_() function without checking for having been initialized. This can cause server crash if init_scan_() has not completed successfully.

      int federatedx_handler_base::end_scan_()
      {
        DBUG_ENTER("ha_federatedx_derived_handler::end_scan");
        (*iop)->free_result(stored_result);
        free_share(txn, share);
        DBUG_RETURN(0);
      }
      

      Attachments

        Activity

          oleg.smirnov Oleg Smirnov created issue -
          oleg.smirnov Oleg Smirnov made changes -
          Field Original Value New Value
          Description 1. Class ha_federatedx_derived_handler overrides virtual function derived_handler::print_error() with an empty implementation which causes problems with error handling. Errors are being simply ignored and occur during later processing.
          {code}
          void ha_federatedx_derived_handler::print_error(int, unsigned long)
          {
          }
          {code}

          2. Members of federatedx_handler_base are accessed in the end_scan_() function without checking for having been initialized. This can cause server crash if init_scan_() has not completed successfully.
          {code}
          int federatedx_handler_base::end_scan_()
          {
            DBUG_ENTER("ha_federatedx_derived_handler::end_scan");
            (*iop)->free_result(stored_result);
            free_share(txn, share);
            DBUG_RETURN(0);
          }
          1. Class ha_federatedx_derived_handler overrides virtual function derived_handler::print_error() with an empty implementation which causes problems with error handling. Errors are being simply ignored and occur during later processing.
          {code}
          void ha_federatedx_derived_handler::print_error(int, unsigned long)
          {
          }
          {code}

          2. Members of federatedx_handler_base are accessed in the end_scan_() function without checking for having been initialized. This can cause server crash if init_scan_() has not completed successfully.
          {code}
          int federatedx_handler_base::end_scan_()
          {
            DBUG_ENTER("ha_federatedx_derived_handler::end_scan");
            (*iop)->free_result(stored_result);
            free_share(txn, share);
            DBUG_RETURN(0);
          }
          {code}
          oleg.smirnov Oleg Smirnov made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          oleg.smirnov Oleg Smirnov made changes -
          Assignee Oleg Smirnov [ JIRAUSER50405 ] Sergei Petrunia [ psergey ]
          Status In Progress [ 3 ] In Review [ 10002 ]

          People

            psergei Sergei Petrunia
            oleg.smirnov Oleg Smirnov
            Votes:
            1 Vote for this issue
            Watchers:
            2 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.