From f3d675ecef8efc21165a6eef76fac408c7ff56fe Mon Sep 17 00:00:00 2001 From: Lance Andersen Date: Tue, 10 May 2011 14:41:18 -0400 Subject: [PATCH] 7043443: address missed reason initialization in BatchUpdateException Reviewed-by: alanb --- jdk/src/share/classes/java/sql/BatchUpdateException.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/jdk/src/share/classes/java/sql/BatchUpdateException.java b/jdk/src/share/classes/java/sql/BatchUpdateException.java index 4fa6241169f..8405da2dac7 100644 --- a/jdk/src/share/classes/java/sql/BatchUpdateException.java +++ b/jdk/src/share/classes/java/sql/BatchUpdateException.java @@ -89,7 +89,7 @@ public class BatchUpdateException extends SQLException { * The cause is not initialized, and may subsequently be * initialized by a call to the * {@link Throwable#initCause(java.lang.Throwable)} method. The vendor code - * is intialized to 0. + * is initialized to 0. *

* * @param reason a description of the exception @@ -188,7 +188,7 @@ public class BatchUpdateException extends SQLException { * @since 1.6 */ public BatchUpdateException(Throwable cause) { - this(null, null, 0, null, cause); + this((cause == null ? null : cause.toString()), null, 0, null, cause); } /** @@ -214,7 +214,7 @@ public class BatchUpdateException extends SQLException { * @since 1.6 */ public BatchUpdateException(int []updateCounts , Throwable cause) { - this(null, null, 0, updateCounts, cause); + this((cause == null ? null : cause.toString()), null, 0, updateCounts, cause); } /**