]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Use Commons IO methods
authorJeremias Maerki <jeremias@apache.org>
Fri, 4 Jul 2003 19:45:06 +0000 (19:45 +0000)
committerJeremias Maerki <jeremias@apache.org>
Fri, 4 Jul 2003 19:45:06 +0000 (19:45 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@196592 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/pdf/PDFFactory.java

index ec5d772a687548e4da3e9efcc2d6704ad8c2afd8..cab819d760326b739631fb310d27ae2d4f7a30c4 100644 (file)
  */ 
 package org.apache.fop.pdf;
 
+// Java
 import java.awt.geom.Rectangle2D;
 import java.io.IOException;
 import java.io.InputStream;
 import java.util.List;
 import java.util.Map;
 
-import org.apache.fop.util.StreamUtilities;
+// Apache libs
 import org.apache.avalon.framework.container.ContainerUtil;
+import org.apache.commons.io.IOUtil;
+
+// FOP
 import org.apache.fop.fonts.CIDFont;
 import org.apache.fop.fonts.CustomFont;
 import org.apache.fop.fonts.Font;
@@ -1163,7 +1167,7 @@ public class PDFFactory {
                         embeddedFont = new PDFT1Stream();
                         ((PDFT1Stream)embeddedFont).setData(pfb);
                     } else {
-                        byte[] file = StreamUtilities.toByteArray(in, 128000);
+                        byte[] file = IOUtil.toByteArray(in);
                         embeddedFont = new PDFTTFStream(file.length);
                         ((PDFTTFStream)embeddedFont).setData(file, file.length);
                     }