summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZhao Yakui <yakui.zhao@intel.com>2009-08-31 13:51:01 +0800
committerZhenyu Wang <zhenyuw@linux.intel.com>2009-09-22 10:59:00 +0800
commit7ae1d0dde6cef3437b67dbc21384cb179616a6c0 (patch)
tree090ad1f2508185575f06a997c9a7e9305c7fb237
parent02fe9be695f7e209944bd0f7b67950f93619feee (diff)
Skip setting tv format property if output crtc is NULL
When TV is not connected and X start, after plugging TV cable again, system will crash because output crtc is NULL. This patch will return, do not handle crtc immediately, meanwhile set value will be effective until user really enable output by xrandr command. Signed-off-by: Ma Ling <ling.ma@intel.com> Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
-rw-r--r--src/i830_tv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/i830_tv.c b/src/i830_tv.c
index 7082aba9..df92a355 100644
--- a/src/i830_tv.c
+++ b/src/i830_tv.c
@@ -1819,7 +1819,7 @@ i830_tv_set_property(xf86OutputPtr output, Atom property,
xfree (dev_priv->tv_format);
dev_priv->tv_format = val;
- if (pI830->starting)
+ if (pI830->starting || output->crtc == NULL)
return TRUE;
/* TV format change will generate new modelines, try