diff options
author | Alex Deucher <alex@t41p.hsd1.va.comcast.net> | 2007-10-11 19:09:45 -0400 |
---|---|---|
committer | Alex Deucher <alex@t41p.hsd1.va.comcast.net> | 2007-10-11 19:09:45 -0400 |
commit | 1148d332f52f3780897aae3fcd5d6a67687c42cd (patch) | |
tree | 46f9478e3694772167de5142cb3257bd1bec4f73 | |
parent | 905b19df33d6f912336b65895e97775ffec07728 (diff) |
RADEON: fix potential crash in mode handling
-rw-r--r-- | src/radeon_modes.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/radeon_modes.c b/src/radeon_modes.c index 6252ea05..e01c1e13 100644 --- a/src/radeon_modes.c +++ b/src/radeon_modes.c @@ -224,11 +224,13 @@ RADEONProbeOutputModes(xf86OutputPtr output) if (output->status == XF86OutputStatusConnected) { if (radeon_output->type == OUTPUT_DVI || radeon_output->type == OUTPUT_VGA) { - edid_mon = xf86OutputGetEDID (output, radeon_output->pI2CBus); - xf86OutputSetEDID (output, edid_mon); + if (output->MonInfo) { + edid_mon = xf86OutputGetEDID (output, radeon_output->pI2CBus); + xf86OutputSetEDID (output, edid_mon); - modes = xf86OutputGetEDIDModes (output); - return modes; + modes = xf86OutputGetEDIDModes (output); + return modes; + } } if (radeon_output->type == OUTPUT_STV || radeon_output->type == OUTPUT_CTV) { modes = RADEONTVModes(output); |