[xlinq] fix bug #23318 - XComment.ToString() accepts "invalid" values.

Before it passes the value to XmlWriter.WriteComment(), it replaces
invalid values to valid form.