Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-4425

Short command in Gogo Shell not working with Java 8

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • gogo.shell-0.12.0
    • Gogo Command
    • None
    • Java 8

    Description

      The bug comes from the different interpretation of String.split() method in line 474 of org.apache.felix.gogo.options.Options (in Gogo Shell).

      Here are the different results of the split method:
      String val = "-k".substring(1).split("");
      Java < 8:
      val[0]=""
      val[1]="k"

      Java 8:
      val[0]="k"

      A simple fix can be an iteration of the characters instead of using split().

      Attachments

        Activity

          People

            rickhall Richard S. Hall
            nroduit Nicolas Roduit
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: