Uploaded image for project: 'MariaDB MaxScale'
  1. MariaDB MaxScale
  2. MXS-1296

Lowercase start transaction is not detected

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Blocker
    • Resolution: Fixed
    • 2.1.3
    • 2.1.4
    • Core
    • None

    Description

      Executing a start transaction statement with all characters in lowercase fails to be detected as the starting edge of a transaction.

      This is caused by the following case-sensitive check for the character T in trxboundaryprser.hh on line 773:

                  case 's':
                  case 'S':
                      if (is_next_alpha('E'))
                      {
                          if (is_next_alpha('S', 2))
                          {
                              token = expect_token(TBP_EXPECT_TOKEN("SESSION"), TK_SESSION);
                          }
                          else
                          {
                              token = expect_token(TBP_EXPECT_TOKEN("SET"), TK_SET);
                          }
                      }
                      else if (is_next_alpha('N'))
                      {
                          token = expect_token(TBP_EXPECT_TOKEN("SNAPSHOT"), TK_SNAPSHOT);
                      }
                      else if (is_next_char('T'))
                      {
                          token = expect_token(TBP_EXPECT_TOKEN("START"), TK_START);
                      }
                      break;
      

      As all tokens can be lowercase, the use of the is_next_char function should be replaced with is_next_alpha.

      Attachments

        Activity

          People

            markus makela markus makela
            markus makela markus makela
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

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