Using -O3 gcc notes that m could reach beyound the end of the EstIIIModes array, if the last bits of the 11s byte where set. Fix this, by extending the array to cover all possible bits from est. Signed-off-by: Torsten Kaiser --- a/hw/xfree86/modes/xf86EdidModes.c 2012-07-06 07:38:43.425573588 +0200 +++ b/hw/xfree86/modes/xf86EdidModes.c 2012-07-06 07:42:24.055572610 +0200 @@ -723,7 +723,13 @@ 1920, 1200, 75, 0}, { 1920, 1200, 85, 0}, { 1920, 1440, 60, 0}, { -1920, 1440, 75, 0},}; + 1920, 1440, 75, 0}, + /* fill up last byte */ + { + 0,0,0,0}, { + 0,0,0,0}, { + 0,0,0,0}, { + 0,0,0,0}, }; static DisplayModePtr DDCModesFromEstIII(unsigned char *est) @@ -735,7 +741,8 @@ for (j = 7; j > 0; j--) { if (est[i] & (1 << j)) { m = (i * 8) + (7 - j); - modes = xf86ModesAdd(modes, + if (EstIIIModes[m].w) + modes = xf86ModesAdd(modes, FindDMTMode(EstIIIModes[m].w, EstIIIModes[m].h, EstIIIModes[m].r,