Fixed sig11 which occured when calling a CloseDisplay() after

XScreenSaverSetAttributes() followed by XScreenSaverUnsetAttributes().
    Caused by missing FreeResource() in XScreenSaverUnsetAttributes().
Removing unused DDC sections that caused misinterpretation of DDC data due
    to a missing break statement in a switch.
Fixed typo: #if <-> #ifdef.
This commit is contained in:
Egbert Eich 2004-11-01 16:05:27 +00:00
parent 7e588ba9ab
commit 1074992c28
3 changed files with 4 additions and 9 deletions

View File

@ -1,4 +1,4 @@
/* $XdotOrg: xc/programs/Xserver/Xext/saver.c,v 1.2 2004/04/23 18:44:41 eich Exp $ */ /* $XdotOrg: xc/programs/Xserver/Xext/saver.c,v 1.3 2004/10/10 17:48:43 herrb Exp $ */
/* /*
* $XConsortium: saver.c,v 1.12 94/04/17 20:59:36 dpw Exp $ * $XConsortium: saver.c,v 1.12 94/04/17 20:59:36 dpw Exp $
* *
@ -1185,6 +1185,7 @@ ScreenSaverUnsetAttributes (ClientPtr client)
pPriv = GetScreenPrivate (pDraw->pScreen); pPriv = GetScreenPrivate (pDraw->pScreen);
if (pPriv && pPriv->attr && pPriv->attr->client == client) if (pPriv && pPriv->attr && pPriv->attr->client == client)
{ {
FreeResource (pPriv->attr->resource, AttrType);
FreeScreenAttr (pPriv->attr); FreeScreenAttr (pPriv->attr);
pPriv->attr = NULL; pPriv->attr = NULL;
CheckScreenPrivate (pDraw->pScreen); CheckScreenPrivate (pDraw->pScreen);

View File

@ -731,19 +731,13 @@ configureDDCMonitorSection (int screennum)
for (i=0;i<4;i++) { for (i=0;i<4;i++) {
switch (ConfiguredMonitor->det_mon[i].type) { switch (ConfiguredMonitor->det_mon[i].type) {
case DT:
case DS_STD_TIMINGS:
case DS_WHITE_P:
break;
case DS_NAME: case DS_NAME:
ptr->mon_modelname = xf86confrealloc(ptr->mon_modelname, ptr->mon_modelname = xf86confrealloc(ptr->mon_modelname,
strlen((char*)(ConfiguredMonitor->det_mon[i].section.name)) strlen((char*)(ConfiguredMonitor->det_mon[i].section.name))
+ 1); + 1);
strcpy(ptr->mon_modelname, strcpy(ptr->mon_modelname,
(char*)(ConfiguredMonitor->det_mon[i].section.name)); (char*)(ConfiguredMonitor->det_mon[i].section.name));
break; break;
case DS_ASCII_STR:
case DS_SERIAL:
case DS_RANGES: case DS_RANGES:
ptr->mon_hsync[ptr->mon_n_hsync].lo = ptr->mon_hsync[ptr->mon_n_hsync].lo =
ConfiguredMonitor->det_mon[i].section.ranges.min_h; ConfiguredMonitor->det_mon[i].section.ranges.min_h;

View File

@ -273,7 +273,7 @@ void ix86PciSelectCfgmech(void)
switch (xf86Info.pciFlags) { switch (xf86Info.pciFlags) {
case PCIOsConfig: case PCIOsConfig:
#if ARCH_PCI_OS_INIT #ifdef ARCH_PCI_OS_INIT
return; return;
#endif #endif