diff --git a/flying-saucer-core/src/main/java/org/xhtmlrenderer/test/ReferenceComparison.java b/flying-saucer-core/src/main/java/org/xhtmlrenderer/test/ReferenceComparison.java index f3d035a8c..19862edf9 100644 --- a/flying-saucer-core/src/main/java/org/xhtmlrenderer/test/ReferenceComparison.java +++ b/flying-saucer-core/src/main/java/org/xhtmlrenderer/test/ReferenceComparison.java @@ -270,12 +270,12 @@ private void checking(File source) { private void report() { int failed = 0; - for (File file : files.keySet()) { - Result result = files.get(file); + for (Map.Entry entry : files.entrySet()) { + Result result = entry.getValue(); if (result instanceof FailedResult) { failed++; - System.out.println(result.describe(file)); + System.out.println(result.describe(entry.getKey())); } } System.out.println("Checked " + files.keySet().size() + " files, " + (failed > 0 ? failed + " failed." : "all OK.")); @@ -332,4 +332,4 @@ public String describe(File file) { } } -} \ No newline at end of file +} diff --git a/flying-saucer-pdf/src/main/java/org/xhtmlrenderer/pdf/util/XHtmlMetaToPdfInfoAdapter.java b/flying-saucer-pdf/src/main/java/org/xhtmlrenderer/pdf/util/XHtmlMetaToPdfInfoAdapter.java index 0a7a6474b..f6d5bd334 100644 --- a/flying-saucer-pdf/src/main/java/org/xhtmlrenderer/pdf/util/XHtmlMetaToPdfInfoAdapter.java +++ b/flying-saucer-pdf/src/main/java/org/xhtmlrenderer/pdf/util/XHtmlMetaToPdfInfoAdapter.java @@ -222,8 +222,9 @@ private void parseHtmlMetaTags( Document doc ) { */ private void addPdfMetaValuesToPdfDocument( ITextRenderer renderer ) { - for (PdfName pdfName : this.pdfInfoValues.keySet()) { - PdfString pdfString = pdfInfoValues.get(pdfName); + for (Map.Entry entry : pdfInfoValues.entrySet()) { + PdfName pdfName = entry.getKey(); + PdfString pdfString = entry.getValue(); XRLog.render(Level.FINEST, "pdfName=" + pdfName + ", pdfString=" + pdfString); renderer.getOutputDevice().getWriter().getInfo().put(pdfName, pdfString); }