Number: 66
Title: & chars are not escaped when outputing SVG
Submitter: Emmanuel Pietriga
Date: Mon Dec 10 10:52:28 2001
Subsys: Dot
Version: 1.7.6
System: x86-Other-Win2000
Severity: major
Problem:
If the input DOT file contains ampersands ('&'), like in "Literal_150" [shape=box,label="Protocols & Format WG",URL="P1"];

these are not escaped as & or & when requesting an SVG output, resulting in NOT well-formed XML documents that cannot be parsed correctly.

This is a major bug for people using the SVG output, since it means that you cannot parse the SVG file.

Emmanuel
Input:

"Literal_150" [shape=box,label="Protocols & Format WG",URL="P1"];

I'm justing giving a sample of the file illustrating the source of the problem (it is huge, about 600Kb)
Fix:
This should be easy to fix (when serializing your SVG from DOT, just replace & by & or better &).

You might also want to check that '<' '>' '"' and "'" are escaped properly (I haven't checked these, and I do not know what is allowed exactly in DOT files w.r.t these chars)
Owner: north
Status: Fixed