Created attachment 15609 [details]
When using GIS software to plot complex filled polygons, I can consistently crash the X server. I have tried this with Ubuntu Gutsy and Hardy, and I believe it applies to earlier versions as well. I have seen this on three different machines and with three different video drivers (nvidia, vesa, intel). I am attaching a full backtrace. I can provide detailed instruction on how to trigger the bug if needed.
This is the output of X -version. I believe this applies to many recent Xorg releases.
X Window System Version 1.3.0
Release Date: 19 April 2007
X Protocol Version 11, Revision 0, Release 1.3
Build Operating System: Linux Ubuntu (xorg-server 2:220.127.116.11.dfsg-12ubuntu8.3)
Current Operating System: Linux patagonicus 2.6.22-14-generic #1 SMP Tue Dec 18 08:02:57 UTC 2007 i686
Build Date: 18 January 2008
If you want to reproduce the bug on Ubuntu, try
wget http://www.keittlab.org/~tkeitt/melanesia.tgz -O- | tar zxvf -
apt-get install r-base-core, libgdal1-dev
install.packages('rgdal', dep = T)
(restart R as ordinary user)
x <- readOGR('melanesia.shp', 'melanesia')
plot(x) # OK!
plot(x, col = 'grey') # segfaults Xorg
I did an experiment to see whether the segfault results from the properties of the individual polygons or instead has something to do with the scale at which the polygon is drawn. What I did was plot each polygon (filled) in the dataset separately. This did not cause X to crash. What that means is that no single polygon in the set is pathological. What I believe is happening is that some of the polygons are tiny compared to the overall geographic extent of the data. When you plot the entire dataset, some polygons are below the size of a single pixel and therefore there is nothing to fill. That I suspect may trigger the bug.
I reliably get this crash as well, using qgis-1.1.0 on a Debian Lenny with X 1.4.2. with one of my own shapefiles and the previously posted micronesia example.
I see similar reports on https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/208899
Based on the downstream ubuntu bug report, this is fixed.