DDC overules xorg.conf displaysize

Remy Bosch remybosch at zonnet.nl
Sat May 5 17:02:41 PDT 2007


Hi, all.

I'm using xorg-server-1.3.0.0 and found that DDC overrules the
DisplaySize option in xorg.conf. Shouldn't variables be tested before
their value is overwritten?
If we look in hw/xfree86/ddc/ddcProperty.c from line 317:
    Monitor->widthmm = 10 * DDC->features.hsize;
    Monitor->heightmm = 10 * DDC->features.vsize;

These lines bluntly overwrite the value written without testing.
By just checking for a value in Monitor->widthmm and Monitor->heightmm
you can prevent overwriting the size of the config.

Like this:
    if (Monitor->widthmm <= 0)
        Monitor->widthmm = 10 * DDC->features.hsize;
    if (Monitor->heightmm <= 0)
        Monitor->heightmm = 10 * DDC->features.vsize;


This is an old bug btw. See:
http://bugs.gentoo.org/show_bug.cgi?id=163705

and here:
https://bugs.freedesktop.org/show_bug.cgi?id=9758



Regards,

Remy



More information about the xorg mailing list