Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6238869

Dead store to local variable in javax.swing.plaf.basic.BasicFileChooserUI$GlobFilter.setPattern

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b32
    • CPU:
      generic
    • OS:
      generic

      Description

      In method javax.swing.plaf.basic.BasicFileChooserUI$GlobFilter.setPattern(String) there is an assignment to a local object called "buf", but it is never used in the method.

      public class BasicFileChooserUI extends FileChooserUI {
      [--snip--]
          class GlobFilter extends FileFilter {
      Pattern pattern;
      String globPattern;

      public void setPattern(String globPattern) {
      char[] gPat = globPattern.toCharArray();
      char[] rPat = new char[gPat.length * 2];
      boolean isWin32 = (File.separatorChar == '\\');
      boolean inBrackets = false;
      StringBuffer buf = new StringBuffer(); // <-----------here
      int j = 0;
      [--snip--]

      ###@###.### 2005-03-10 16:22:20 GMT

        Attachments

          Activity

            People

            Assignee:
            shickeysunw Shannon Hickey (Inactive)
            Reporter:
            jloefflm Johann Löfflmann (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: