You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by bc...@apache.org on 2004/11/22 08:57:34 UTC
cvs commit: xml-fop/src/java/org/apache/fop/fo PropertyList.java
bckfnn 2004/11/21 23:57:34
Modified: src/java/org/apache/fop/fo PropertyList.java
Log:
Handle unknown subproperty names by logging an error message and ignoring
the property value.
PR: 32338
Revision Changes Path
1.41 +5 -2 xml-fop/src/java/org/apache/fop/fo/PropertyList.java
Index: PropertyList.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/fo/PropertyList.java,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- PropertyList.java 28 Oct 2004 10:00:20 -0000 1.40
+++ PropertyList.java 22 Nov 2004 07:57:34 -0000 1.41
@@ -308,6 +308,10 @@
Property baseProperty = findBaseProperty(attributes,
parentFO, propId, basePropertyName, propertyMaker);
int subpropId = FOPropertyMapping.getSubPropertyId(subPropertyName);
+ if (subpropId == -1) {
+ handleInvalidProperty(attributeName);
+ return;
+ }
prop = propertyMaker.make(baseProperty, subpropId,
this, attributeValue, parentFO);
}
@@ -353,8 +357,7 @@
private void handleInvalidProperty(String attributeName) {
if (!attributeName.startsWith("xmlns")) {
- //log.error("property '"
- // + attributeName + "' ignored");
+ log.error("property '" + attributeName + "' ignored");
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-cvs-help@xml.apache.org