diff options
author | marha <marha@users.sourceforge.net> | 2012-03-23 10:05:55 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-03-23 10:05:55 +0100 |
commit | 0f834b91a4768673833ab4917e87d86c237bb1a6 (patch) | |
tree | 363489504ed4b2d360259b8de4c9e392918e5d02 /xorg-server/hw/xfree86/ddc/ddcProperty.c | |
parent | fc72edebf875378459368c5383d9023730cbca54 (diff) | |
download | vcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.tar.gz vcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.tar.bz2 vcxsrv-0f834b91a4768673833ab4917e87d86c237bb1a6.zip |
libX11 xserver fontconfig mesa pixman xkbcomp xkeyboard-config git update
23 Mar 2012
Diffstat (limited to 'xorg-server/hw/xfree86/ddc/ddcProperty.c')
-rw-r--r-- | xorg-server/hw/xfree86/ddc/ddcProperty.c | 31 |
1 files changed, 16 insertions, 15 deletions
diff --git a/xorg-server/hw/xfree86/ddc/ddcProperty.c b/xorg-server/hw/xfree86/ddc/ddcProperty.c index c3aced5c2..fc63f0e8a 100644 --- a/xorg-server/hw/xfree86/ddc/ddcProperty.c +++ b/xorg-server/hw/xfree86/ddc/ddcProperty.c @@ -40,8 +40,8 @@ edidMakeAtom(int i, const char *name, CARD8 *data, int size) Atom atom; unsigned char *atom_data; - if (!(atom_data = malloc(size*sizeof(CARD8)))) - return; + if (!(atom_data = malloc(size * sizeof(CARD8)))) + return; atom = MakeAtom(name, strlen(name), TRUE); memcpy(atom_data, data, size); @@ -54,17 +54,19 @@ addRootWindowProperties(ScrnInfoPtr pScrn, xf86MonPtr DDC) int scrnIndex = pScrn->scrnIndex; if (DDC->flags & MONITOR_DISPLAYID) { - /* Don't bother, use RANDR already */ - return; - } else if (DDC->ver.version == 1) { - int size = 128 + - (DDC->flags & EDID_COMPLETE_RAWDATA ? DDC->no_sections * 128 : 0); + /* Don't bother, use RANDR already */ + return; + } + else if (DDC->ver.version == 1) { + int size = 128 + + (DDC->flags & EDID_COMPLETE_RAWDATA ? DDC->no_sections * 128 : 0); - edidMakeAtom(scrnIndex, EDID1_ATOM_NAME, DDC->rawData, size); - } else { - xf86DrvMsg(scrnIndex, X_PROBED, "unexpected EDID version %d.%d\n", - DDC->ver.version, DDC->ver.revision); - return; + edidMakeAtom(scrnIndex, EDID1_ATOM_NAME, DDC->rawData, size); + } + else { + xf86DrvMsg(scrnIndex, X_PROBED, "unexpected EDID version %d.%d\n", + DDC->ver.version, DDC->ver.revision); + return; } } @@ -74,10 +76,9 @@ xf86SetDDCproperties(ScrnInfoPtr pScrn, xf86MonPtr DDC) if (!pScrn || !pScrn->monitor || !DDC) return FALSE; - if (DDC->flags & MONITOR_DISPLAYID) - ; + if (DDC->flags & MONITOR_DISPLAYID); else - xf86EdidMonitorSet(pScrn->scrnIndex, pScrn->monitor, DDC); + xf86EdidMonitorSet(pScrn->scrnIndex, pScrn->monitor, DDC); addRootWindowProperties(pScrn, DDC); |