--- a/jaxp/src/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMsg.java Wed Jul 05 18:46:58 2017 +0200
+++ b/jaxp/src/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMsg.java Mon Feb 18 11:33:35 2013 -0800
@@ -23,6 +23,7 @@
package com.sun.org.apache.xalan.internal.xsltc.compiler.util;
+import com.sun.org.apache.xalan.internal.utils.SecuritySupport;
import java.text.MessageFormat;
import java.util.Locale;
import java.util.ResourceBundle;
@@ -46,6 +47,8 @@
Object[] _params = null;
private boolean _isWarningError;
+ Throwable _cause;
+
// Compiler error messages
public static final String MULTIPLE_STYLESHEET_ERR = "MULTIPLE_STYLESHEET_ERR";
public static final String TEMPLATE_REDEF_ERR = "TEMPLATE_REDEF_ERR";
@@ -165,6 +168,8 @@
public static final String OUTLINE_ERR_METHOD_TOO_BIG =
"OUTLINE_ERR_METHOD_TOO_BIG";
+ public static final String DESERIALIZE_TRANSLET_ERR = "DESERIALIZE_TEMPLATES_ERR";
+
// All error messages are localized and are stored in resource bundles.
// This array and the following 4 strings are read from that bundle.
private static ResourceBundle _bundle;
@@ -175,7 +180,7 @@
public final static String RUNTIME_ERROR_KEY = "RUNTIME_ERROR_KEY";
static {
- _bundle = ResourceBundle.getBundle(
+ _bundle = SecuritySupport.getResourceBundle(
"com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMessages",
Locale.getDefault());
}
@@ -185,10 +190,11 @@
_line = 0;
}
- public ErrorMsg(Throwable e) {
- _code = null;
+ public ErrorMsg(String code, Throwable e) {
+ _code = code;
_message = e.getMessage();
_line = 0;
+ _cause = e;
}
public ErrorMsg(String message, int line) {
@@ -240,6 +246,10 @@
_params[1] = param2;
}
+ public Throwable getCause() {
+ return _cause;
+ }
+
private String getFileName(SyntaxTreeNode node) {
Stylesheet stylesheet = node.getStylesheet();
if (stylesheet != null)