xserver: Branch 'master'
Zhenyu Wang
zhen at kemper.freedesktop.org
Tue Oct 7 22:38:20 PDT 2008
hw/xfree86/modes/xf86Crtc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 56c615368c5a8e7acb0398434c2c68578626aa38
Author: Zhenyu Wang <zhenyu.z.wang at intel.com>
Date: Wed Oct 8 13:33:55 2008 +0800
Check nextEnabledOutput()'s return in bestModeForAspect()
In case no enabled outputs, we will reference wrong index of
output array.
diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index ed2ae7a..df47598 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -1912,7 +1912,8 @@ bestModeForAspect(xf86CrtcConfigPtr config, Bool *enabled, float aspect)
int o = -1, p;
DisplayModePtr mode = NULL, test = NULL, match = NULL;
- nextEnabledOutput(config, enabled, &o);
+ if (!nextEnabledOutput(config, enabled, &o))
+ return NULL;
while ((mode = nextAspectMode(config->output[o], mode, aspect))) {
test = mode;
for (p = o; nextEnabledOutput(config, enabled, &p); ) {
More information about the xorg-commit
mailing list