• Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • sloccount-plugin
    • None
    • Bug in code logic

      If an exception occurs before the stream is closed there will be a resource leak since close() won't be called. Use try-finally pattern.

          private void parse(java.io.File file, SloccountReportInterface report) throws IOException {
              InputStreamReader in = new InputStreamReader(new FileInputStream(file), encoding);
              this.parse(in, report);
              in.close();
          }
      

          [JENKINS-21229] Possible resource leak in parser

          Michal Turek created issue -
          Michal Turek made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Michal Turek made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: In Progress [ 3 ] New: Resolved [ 5 ]
          Michal Turek made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 153092 ] New: JNJira + In-Review [ 207295 ]

            mixalturek Michal Turek
            mixalturek Michal Turek
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: