You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While analyzing a problem in our system where we use the openhtmltopdf re noticed that our logs are heavily polluted with stacktraces that are created through a e.printStackTrace() in in the OpenHtmlGvtFont class. Because of our setup we are not able to redirect STDOUT and STDERR into our logging framework. Although the corresponding exception should not happen (according to the code) it would be great if it would be logged using a proper logger and not STDERR.
`
public OpenHtmlGvtFont(byte[] fontBytes, GVTFontFamily family, float size, Float fontWeight, Float fontStyle) throws FontFormatException {
Font font;
try {
font = Font.createFont(Font.TRUETYPE_FONT, new ByteArrayInputStream(fontBytes)).deriveFont(toFontWeight(fontWeight) | toStyle(fontStyle) , size);
} catch (IOException e) {
// Shouldn't happen
e.printStackTrace(); // Although it should not happen, it would be great to use a logger here.
font = null;
}
this.baseFont = font;
this.fontFamily = family;
}
`
The text was updated successfully, but these errors were encountered:
Hello,
While analyzing a problem in our system where we use the openhtmltopdf re noticed that our logs are heavily polluted with stacktraces that are created through a e.printStackTrace() in in the OpenHtmlGvtFont class. Because of our setup we are not able to redirect STDOUT and STDERR into our logging framework. Although the corresponding exception should not happen (according to the code) it would be great if it would be logged using a proper logger and not STDERR.
`
public OpenHtmlGvtFont(byte[] fontBytes, GVTFontFamily family, float size, Float fontWeight, Float fontStyle) throws FontFormatException {
Font font;
`
The text was updated successfully, but these errors were encountered: