Author: rgardler
Date: Fri Dec  1 14:37:22 2006
New Revision: 481431

URL: http://svn.apache.org/viewvc?view=rev&rev=481431
Log:
Check a variable value is present before trying to substitute

Modified:
    
forrest/trunk/whiteboard/forrest2/core/src/core/org/apache/forrest/core/locationMap/Location.java

Modified: 
forrest/trunk/whiteboard/forrest2/core/src/core/org/apache/forrest/core/locationMap/Location.java
URL: 
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest2/core/src/core/org/apache/forrest/core/locationMap/Location.java?view=diff&rev=481431&r1=481430&r2=481431
==============================================================================
--- 
forrest/trunk/whiteboard/forrest2/core/src/core/org/apache/forrest/core/locationMap/Location.java
 (original)
+++ 
forrest/trunk/whiteboard/forrest2/core/src/core/org/apache/forrest/core/locationMap/Location.java
 Fri Dec  1 14:37:22 2006
@@ -223,7 +223,9 @@
                                for (int i = 0; i < r.getParenCount(); i++) {
                                        variable = "$(" + i + ")";
                                        value = r.getParen(i);
-                                       sourceSSP = sourceSSP.replace(variable, 
value);
+                                       if (value != null) {
+                                               sourceSSP = 
sourceSSP.replace(variable, value);
+                                       }
                                }
                                log.debug("After variable substitution a 
potential source path is "
                                                + sourceSSP);