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

Missing readline features when building with external libedit library

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.0.17
    • N/A
    • Scripts & Clients
    • None
    • Fedora

    Description

      There are two issues related to external libedit reported for Fedora: https://bugzilla.redhat.com/show_bug.cgi?id=1187469 that non-ASCII characters don't work in interactive mode and https://bugzilla.redhat.com/show_bug.cgi?id=1180403 that backward search doesn't work.

      The problem is that mysql binary uses just readline() function from libedit library and this function only offers basic functionality. So generally, the possible fix is either to use el_wgets() function from libedit and configure the backward search feature in mysql binary or fix libedit's readline function to offer this by default (of as another function).

      Steps to Reproduce:
      1. run mysql client that uses external libedit
      2. copy & paste the following clauses in mysql client:
      SELECT 'Chinese characters <汉字> are stripped';
      3. '汉字' are stripped out in mysql client
      4. press ctrl+R to activate background search in history

      Actual results:

      MariaDB [(none)]> SELECT 'Chinese characters <> are stripped';
      +------------------------------------+
      | Chinese characters <> are stripped |
      +------------------------------------+
      | Chinese characters <> are stripped |
      +------------------------------------+

      background search in history doesn't work

      Expected results:

      MariaDB [(none)]> SELECT 'Chinese characters <汉字> are stripped';
      +------------------------------------------+
      | Chinese characters <汉字> are stripped   |
      +------------------------------------------+
      | Chinese characters <汉字> are stripped   |
      +------------------------------------------+

      background search in history works

      Reproducible for example with mariadb-10.0.17-1.fc21.

      Attachments

        Activity

          People

            serg Sergei Golubchik
            hhorak Honza Horak
            Votes:
            0 Vote for this issue
            Watchers:
            3 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.