You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-commits@xmlgraphics.apache.org by ca...@apache.org on 2007/12/26 12:45:58 UTC
svn commit: r606891 - in /xmlgraphics/batik/trunk: CHANGES
sources/org/apache/batik/css/engine/CSSEngine.java
sources/org/apache/batik/util/ParsedURL.java
Author: cam
Date: Wed Dec 26 03:45:26 2007
New Revision: 606891
URL: http://svn.apache.org/viewvc?rev=606891&view=rev
Log:
Avoid NPE in ParsedURL constructor. Fixes bug 44054.
Submitted by: Jeremias Märki <jeremias (at) apache.org>
Modified:
xmlgraphics/batik/trunk/CHANGES
xmlgraphics/batik/trunk/sources/org/apache/batik/css/engine/CSSEngine.java
xmlgraphics/batik/trunk/sources/org/apache/batik/util/ParsedURL.java
Modified: xmlgraphics/batik/trunk/CHANGES
URL: http://svn.apache.org/viewvc/xmlgraphics/batik/trunk/CHANGES?rev=606891&r1=606890&r2=606891&view=diff
==============================================================================
--- xmlgraphics/batik/trunk/CHANGES (original)
+++ xmlgraphics/batik/trunk/CHANGES Wed Dec 26 03:45:26 2007
@@ -16,7 +16,7 @@
42543, 42645, 42651, 42697, 42698, 42807, 42961, 42963, 42968,
43022, 43043, 43045, 43165, 43194, 43195, 43370, 43418, 43446,
43638, 43657, 43744, 43760, 43764, 43787, 43854, 43871, 43904,
- 43953, 44029, 44092
+ 43953, 44029, 44054, 44092
2. New features
Modified: xmlgraphics/batik/trunk/sources/org/apache/batik/css/engine/CSSEngine.java
URL: http://svn.apache.org/viewvc/xmlgraphics/batik/trunk/sources/org/apache/batik/css/engine/CSSEngine.java?rev=606891&r1=606890&r2=606891&view=diff
==============================================================================
--- xmlgraphics/batik/trunk/sources/org/apache/batik/css/engine/CSSEngine.java (original)
+++ xmlgraphics/batik/trunk/sources/org/apache/batik/css/engine/CSSEngine.java Wed Dec 26 03:45:26 2007
@@ -824,7 +824,7 @@
styleDeclarationDocumentHandler.styleMap = null;
} catch (Exception e) {
String m = e.getMessage();
- if (m == null) m = "";
+ if (m == null) m = e.getClass().getName();
String u = ((documentURI == null)?"<unknown>":
documentURI.toString());
String s = Messages.formatMessage
Modified: xmlgraphics/batik/trunk/sources/org/apache/batik/util/ParsedURL.java
URL: http://svn.apache.org/viewvc/xmlgraphics/batik/trunk/sources/org/apache/batik/util/ParsedURL.java?rev=606891&r1=606890&r2=606891&view=diff
==============================================================================
--- xmlgraphics/batik/trunk/sources/org/apache/batik/util/ParsedURL.java (original)
+++ xmlgraphics/batik/trunk/sources/org/apache/batik/util/ParsedURL.java Wed Dec 26 03:45:26 2007
@@ -229,11 +229,12 @@
* the missing pieces will be taken from the baseURL.
*/
public ParsedURL(ParsedURL baseURL, String urlStr) {
- userAgent = baseURL.getUserAgent();
- if (baseURL != null)
+ if (baseURL != null) {
+ userAgent = baseURL.getUserAgent();
data = parseURL(baseURL, urlStr);
- else
+ } else {
data = parseURL(urlStr);
+ }
}
/**