Bug report #4509
Crash on SPARC when opening vector layer
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||Sparc Solaris||Easy fix?:||No|
|Pull Request or Patch supplied:||Yes||Resolution:||fixed/implemented|
|Crashes QGIS or corrupts data:||Yes||Copied to github as #:||14431|
QGIS crashes with "signal BUS (invalid address alignment)" on Sparc Solaris when opening a shape file. I have tracked the problem down to src/core/symbology-ng/qgsrendererv2.cpp and I attach a proposed patch. As I understand it, Sparc and other RISC processors only allow memory access on certain memory boundaries so maybe memcpy is safer than pointer casting when dealing with WKBs. It seems other parts of QGIS already do this.
I think this will likely be a problem on ARM chips also as they have a similar limitation.
I am happy to do any other testing on Sparc that may be required.
#11 Updated by Marco Bernasocchi about 6 years ago
patches updated and partly applyed in https://github.com/mbernasocchi/QGIS/tree/androidFixByteAllign. I'll pull request and close this later this week.
#13 Updated by Martin Dobias over 5 years ago
- Resolution set to fixed/implemented
- Status changed from Open to Closed
- Target version changed from Future Release - High Priority to Version 2.2
Some time ago the WKB handling has been updated to use memcpy, so it should be working now in master. Please reopen if there are any remaining issues.