Description
In hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/state/Graph.java :
public void save(String filepath) throws IOException { OutputStreamWriter fout = new OutputStreamWriter( new FileOutputStream(filepath), Charset.forName("UTF-8")); fout.write(generateGraphViz()); fout.close();
The close of fout should be enclosed in finally clause.