Correctly deal with invalid content in non-selfclosing tags. Fixes #297
This commit is contained in:
parent
6745bdf634
commit
761b05b599
@ -128,8 +128,8 @@ tree.Definition.prototype.symbolizersToXML = function(env, symbolizers, zoom) {
|
|||||||
}
|
}
|
||||||
if (selfclosing) {
|
if (selfclosing) {
|
||||||
xml += '/>\n';
|
xml += '/>\n';
|
||||||
} else {
|
} else if (tagcontent) {
|
||||||
if (tagcontent.indexOf('<Format') != -1) {
|
if (tagcontent.indexOf('<') != -1) {
|
||||||
xml += '>' + tagcontent + '</' + name + '>\n';
|
xml += '>' + tagcontent + '</' + name + '>\n';
|
||||||
} else {
|
} else {
|
||||||
xml += '><![CDATA[' + tagcontent + ']]></' + name + '>\n';
|
xml += '><![CDATA[' + tagcontent + ']]></' + name + '>\n';
|
||||||
|
4
test/errorhandling/issue297.mss
Normal file
4
test/errorhandling/issue297.mss
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
#t {
|
||||||
|
text-name: invalid;
|
||||||
|
text-face-name: "Dejagnu";
|
||||||
|
}
|
1
test/errorhandling/issue297.result
Normal file
1
test/errorhandling/issue297.result
Normal file
@ -0,0 +1 @@
|
|||||||
|
issue297.mss:2:2 Invalid value for text-name, the type expression is expected. invalid (of type keyword) was given.
|
Loading…
Reference in New Issue
Block a user