Hadoop Common
  1. Hadoop Common
  2. HADOOP-7194

Potential Resource leak in IOUtils.java

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.21.1, 0.22.0, 0.23.0
    • Component/s: io
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      IOUtils.java
      
      try {
            copyBytes(in, out, buffSize);
          } finally {
            if(close) {
              out.close();
              in.close();
            }
          }
      

      In the above code if any exception throws from the out.close() statement, in.close() statement will not execute and the input stream will not be closed.

        Issue Links

          Activity

            People

            • Assignee:
              Devaraj K
              Reporter:
              Devaraj K
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development