Revision: 7896 http://languagetool.svn.sourceforge.net/languagetool/?rev=7896&view=rev Author: dnaber Date: 2012-08-20 18:44:02 +0000 (Mon, 20 Aug 2012) Log Message: ----------- don't stop with an error on XML entities in the input, instead just ignore them
Modified Paths: -------------- trunk/ltcommunity/grails-app/controllers/org/languagetool/RuleEditorController.groovy Modified: trunk/ltcommunity/grails-app/controllers/org/languagetool/RuleEditorController.groovy =================================================================== --- trunk/ltcommunity/grails-app/controllers/org/languagetool/RuleEditorController.groovy 2012-08-20 18:14:19 UTC (rev 7895) +++ trunk/ltcommunity/grails-app/controllers/org/languagetool/RuleEditorController.groovy 2012-08-20 18:44:02 UTC (rev 7896) @@ -84,6 +84,7 @@ render(template: 'checkXmlProblem', model: [error: "No XML found"]) return } + xml = xml.replaceAll("&([a-zA-Z]+);", "&\$1;") // entities otherwise lead to an error final InputStream input = new ByteArrayInputStream(xml.getBytes()) def rules = loader.getRules(input, "<form>") if (rules.size() == 0) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Languagetool-cvs mailing list Languagetool-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/languagetool-cvs