Re: spice-salt patch

peter-4lf8KW9E9MLMqX/[email protected] Tue, 28 Oct 2003 10:24:23 +1100
Newsgroups gmane.comp.java.spice.devel
Message-ID <015201c39ce1$74a8f3b0$21e7809d@fisg2>
Applied - thanks!

----- Original Message -----
From: "Mircea Toma" <[email protected]>
To: <[email protected]>
Sent: Tuesday, October 28, 2003 10:09 AM
Subject: spice-salt patch


> This is a patch for ExceptionUtil.java. It throws a NPE when the stack
> trace contains an exception with a null cause.
>
> Mircea
>


----------------------------------------------------------------------------
----


> Index:
components/salt/src/java/org/realityforge/salt/lang/ExceptionUtil.java
> ===================================================================
> RCS file:
/cvsroot/spice/spice/components/salt/src/java/org/realityforge/salt/lang/Exc
eptionUtil.java,v
> retrieving revision 1.13
> diff -u -r1.13 ExceptionUtil.java
> --- components/salt/src/java/org/realityforge/salt/lang/ExceptionUtil.java
18 Oct 2003 07:30:02 -0000 1.13
> +++ components/salt/src/java/org/realityforge/salt/lang/ExceptionUtil.java
27 Oct 2003 22:53:19 -0000
> @@ -135,7 +135,7 @@
>          boolean outputTrace = false;
>          final Throwable root = getRootCause( throwable );
>          Throwable element = getCause( throwable );
> -        while( root != element )
> +        while( ( null != element ) && ( root != element ) )
>          {
>              sb.append( "--- Rethrown From ---" );
>              sb.append( LINE_SEPARATOR );
>



-------------------------------------------------------
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/