aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-03-25 10:23:25 +0100
committermarha <marha@users.sourceforge.net>2013-03-25 10:23:25 +0100
commit30ac3efa02bbd1aecff4a0aa2da17bc886bdd5ea (patch)
tree7ae924e3fb64c93a0f59e55fd08a914db9bb551b /xorg-server/hw/xfree86
parent55a9a54c65cd0ff58966408ea4d7879a3d9c749c (diff)
parent176eab9e8277db1549bfc6c9ae805c4e1858f0b0 (diff)
downloadvcxsrv-30ac3efa02bbd1aecff4a0aa2da17bc886bdd5ea.tar.gz
vcxsrv-30ac3efa02bbd1aecff4a0aa2da17bc886bdd5ea.tar.bz2
vcxsrv-30ac3efa02bbd1aecff4a0aa2da17bc886bdd5ea.zip
Merge remote-tracking branch 'origin/released'
* origin/released: fontconfig mesa pixman xserver git update 25 Mar 2013
Diffstat (limited to 'xorg-server/hw/xfree86')
-rw-r--r--xorg-server/hw/xfree86/common/xf86Events.c1
-rw-r--r--xorg-server/hw/xfree86/common/xf86Mode.c17
-rw-r--r--xorg-server/hw/xfree86/common/xf86Option.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86fbman.c12
-rw-r--r--xorg-server/hw/xfree86/common/xf86xvmc.c4
-rw-r--r--xorg-server/hw/xfree86/ddc/ddc.c7
-rw-r--r--xorg-server/hw/xfree86/ramdac/xf86Cursor.c1
7 files changed, 22 insertions, 22 deletions
diff --git a/xorg-server/hw/xfree86/common/xf86Events.c b/xorg-server/hw/xfree86/common/xf86Events.c
index d92174edf..055223310 100644
--- a/xorg-server/hw/xfree86/common/xf86Events.c
+++ b/xorg-server/hw/xfree86/common/xf86Events.c
@@ -413,7 +413,6 @@ static void
xf86VTSwitch(void)
{
int i;
- static int prevSIGIO;
InputInfoPtr pInfo;
IHPtr ih;
diff --git a/xorg-server/hw/xfree86/common/xf86Mode.c b/xorg-server/hw/xfree86/common/xf86Mode.c
index d80dec892..706ab64fc 100644
--- a/xorg-server/hw/xfree86/common/xf86Mode.c
+++ b/xorg-server/hw/xfree86/common/xf86Mode.c
@@ -1370,7 +1370,6 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
int saveType;
PixmapFormatRec *BankFormat;
ClockRangePtr cp;
- ClockRangePtr storeClockRanges;
int numTimings = 0;
range hsync[MAX_HSYNC];
range vrefresh[MAX_VREFRESH];
@@ -1492,16 +1491,14 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
/*
* Store the clockRanges for later use by the VidMode extension.
*/
- storeClockRanges = scrp->clockRanges;
- while (storeClockRanges != NULL) {
- storeClockRanges = storeClockRanges->next;
- }
- for (cp = clockRanges; cp != NULL; cp = cp->next,
- storeClockRanges = storeClockRanges->next) {
- storeClockRanges = xnfalloc(sizeof(ClockRange));
+ nt_list_for_each_entry(cp, clockRanges, next) {
+ ClockRangePtr newCR = xnfalloc(sizeof(ClockRange));
+ memcpy(newCR, cp, sizeof(ClockRange));
+ newCR->next = NULL;
if (scrp->clockRanges == NULL)
- scrp->clockRanges = storeClockRanges;
- memcpy(storeClockRanges, cp, sizeof(ClockRange));
+ scrp->clockRanges = newCR;
+ else
+ nt_list_append(newCR, scrp->clockRanges, ClockRange, next);
}
/* Determine which pixmap format to pass to scanLineWidth() */
diff --git a/xorg-server/hw/xfree86/common/xf86Option.c b/xorg-server/hw/xfree86/common/xf86Option.c
index 40c9d15f4..607c33354 100644
--- a/xorg-server/hw/xfree86/common/xf86Option.c
+++ b/xorg-server/hw/xfree86/common/xf86Option.c
@@ -743,7 +743,7 @@ xf86TokenToOptName(const OptionInfoRec * table, int token)
const OptionInfoRec *p;
p = xf86TokenToOptinfo(table, token);
- return p->name;
+ return p ? p->name : NULL;
}
Bool
diff --git a/xorg-server/hw/xfree86/common/xf86fbman.c b/xorg-server/hw/xfree86/common/xf86fbman.c
index c2e7bab9f..4da6af2b6 100644
--- a/xorg-server/hw/xfree86/common/xf86fbman.c
+++ b/xorg-server/hw/xfree86/common/xf86fbman.c
@@ -320,15 +320,17 @@ localRegisterFreeBoxCallback(ScreenPtr pScreen,
newCallbacks = realloc(offman->FreeBoxesUpdateCallback,
sizeof(FreeBoxCallbackProcPtr) *
(offman->NumCallbacks + 1));
+ if (!newCallbacks)
+ return FALSE;
+ else
+ offman->FreeBoxesUpdateCallback = newCallbacks;
newPrivates = realloc(offman->devPrivates,
sizeof(DevUnion) * (offman->NumCallbacks + 1));
-
- if (!newCallbacks || !newPrivates)
+ if (!newPrivates)
return FALSE;
-
- offman->FreeBoxesUpdateCallback = newCallbacks;
- offman->devPrivates = newPrivates;
+ else
+ offman->devPrivates = newPrivates;
offman->FreeBoxesUpdateCallback[offman->NumCallbacks] = FreeBoxCallback;
offman->devPrivates[offman->NumCallbacks].ptr = devPriv;
diff --git a/xorg-server/hw/xfree86/common/xf86xvmc.c b/xorg-server/hw/xfree86/common/xf86xvmc.c
index 78a32bfe1..3169c054c 100644
--- a/xorg-server/hw/xfree86/common/xf86xvmc.c
+++ b/xorg-server/hw/xfree86/common/xf86xvmc.c
@@ -158,8 +158,10 @@ xf86XvMCScreenInit(ScreenPtr pScreen,
if (!(pAdapt = malloc(sizeof(XvMCAdaptorRec) * num_adaptors)))
return FALSE;
- if (!dixRegisterPrivateKey(&XF86XvMCScreenKeyRec, PRIVATE_SCREEN, 0))
+ if (!dixRegisterPrivateKey(&XF86XvMCScreenKeyRec, PRIVATE_SCREEN, 0)) {
+ free(pAdapt);
return FALSE;
+ }
if (!(pScreenPriv = malloc(sizeof(xf86XvMCScreenRec)))) {
free(pAdapt);
diff --git a/xorg-server/hw/xfree86/ddc/ddc.c b/xorg-server/hw/xfree86/ddc/ddc.c
index 28c969646..44c1d535c 100644
--- a/xorg-server/hw/xfree86/ddc/ddc.c
+++ b/xorg-server/hw/xfree86/ddc/ddc.c
@@ -91,15 +91,16 @@ resort(unsigned char *s_block)
unsigned char *d_new, *d_ptr, *d_end, *s_ptr, *s_end;
unsigned char tmp;
+ s_ptr = find_header(s_block);
+ if (!s_ptr)
+ return NULL;
s_end = s_block + EDID1_LEN;
+
d_new = malloc(EDID1_LEN);
if (!d_new)
return NULL;
d_end = d_new + EDID1_LEN;
- s_ptr = find_header(s_block);
- if (!s_ptr)
- return NULL;
for (d_ptr = d_new; d_ptr < d_end; d_ptr++) {
tmp = *(s_ptr++);
*d_ptr = tmp;
diff --git a/xorg-server/hw/xfree86/ramdac/xf86Cursor.c b/xorg-server/hw/xfree86/ramdac/xf86Cursor.c
index 8d48a7542..d32aac1cf 100644
--- a/xorg-server/hw/xfree86/ramdac/xf86Cursor.c
+++ b/xorg-server/hw/xfree86/ramdac/xf86Cursor.c
@@ -16,7 +16,6 @@
* Externing inputInfo is not the nice way to do it but it works.
*/
#include "inputstr.h"
-extern InputInfo inputInfo;
DevPrivateKeyRec xf86CursorScreenKeyRec;