summaryrefslogtreecommitdiffstats
path: root/base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java
diff options
context:
space:
mode:
Diffstat (limited to 'base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java')
-rw-r--r--base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java b/base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java
index e3068d7b3..35ec7c515 100644
--- a/base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java
+++ b/base/common/src/com/netscape/cms/servlet/csadmin/CertUtil.java
@@ -194,7 +194,9 @@ public class CertUtil {
return certReqs;
} catch (Throwable e) {
CMS.debug(e);
- context.put("errorString", e.toString());
+ if (context != null) {
+ context.put("errorString", e.toString());
+ }
CMS.debug("CertUtil getPKCS10: " + e.toString());
throw new IOException(e.toString());
}
@@ -453,8 +455,9 @@ public class CertUtil {
}
if (cr == null) {
- context.put("errorString",
- "Ceritifcate Authority is not ready to serve.");
+ if (context != null) {
+ context.put("errorString", "Ceritifcate Authority is not ready to serve.");
+ }
throw new IOException("Ceritifcate Authority is not ready to serve.");
}