Bug report #15942
Bad GML causes crash
|Category:||Web Services clients/WFS|
|Affected QGIS version:||2.18.7||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||Yes||Copied to github as #:||23858|
I'm writing a WFS 2.0.0 server with GML 3.2. The GML I am serving up currently does NOT meet the GML spec and I didn't expect it to actually work in QGIS yet.
However, trying to add the layer caused QGIS to crash. I would expect an error message or other graceful handling of bad XML instead of a hard crash.
gdalinfo works against the XML without crashing.
I have attached the gml and backtrace (as reported by OSX) below.
I'm on Mac OSX, using the kyngchaos build 2.18.0 with no plugins installed.
Possible lead: When I fixed the namespace declarations in the original <wfs:FeatureCollection> tag QGIS no longer crashes, although the geometry is not displayed (though this is probably due to the GML still being incorrect).
[GML parser/WFS provider] Fix crash when typename and geometry field name are identical (fixes #15942)
#3 Updated by Michael Moore almost 3 years ago
After a more thorough inspection, it looks I've been able to set up a place where you can (probably) reproduce this.
1. Add http://stuporglue.org/qgis/ as a WFS Server Connection
3. Add the geom / walkin:geom layer
QGIS will make three WFS requests:
It will crash after the 3rd.
I have attached the output of these three requests below.
In addition, you can see a .gif of QGIS crashing here: http://stuporglue.org/qgis/
#7 Updated by Giovanni Manghi over 2 years ago
- Subject changed from Bad GML can cause QGIS to crash with SIGSEGV to Bad GML causes crash
- Crashes QGIS or corrupts data changed from No to Yes
- Affected QGIS version changed from 2.18.0 to 2.18.4
- Target version set to Version 2.18
- Priority changed from Normal to High
- Category set to Web Services clients/WFS