#7 Call to equals() comparing different types

open
nobody
None
5
2009-08-26
2009-08-26
Anonymous
No

In com.vividsolutions.jts.io.gml2.GeometryStrategies.java (line 319):

if(arg.text == null || "".equals(arg.text))
throw new SAXException("Cannot create a coordinate sequence without text to parse");

arg.text is StringBuffer then "".equals(arg.text) is allways false. Replace to:

"".equals(arg.text).toString()

or

equals(arg.text).toString().isEmpty()

Discussion