dix: Squash some new gcc6 warnings
-Wlogical-op now tells us: devices.c:1685:23: warning: logical ‘and’ of equal expressions Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
parent
23dfa01729
commit
a5dd7b890f
|
@ -106,7 +106,7 @@ PanoramiXCreateWindow(ClientPtr client)
|
||||||
if ((Mask) stuff->mask & CWColormap) {
|
if ((Mask) stuff->mask & CWColormap) {
|
||||||
cmap_offset = Ones((Mask) stuff->mask & (CWColormap - 1));
|
cmap_offset = Ones((Mask) stuff->mask & (CWColormap - 1));
|
||||||
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
||||||
if ((tmp != CopyFromParent) && (tmp != None)) {
|
if (tmp != CopyFromParent) {
|
||||||
result = dixLookupResourceByType((void **) &cmap, tmp,
|
result = dixLookupResourceByType((void **) &cmap, tmp,
|
||||||
XRT_COLORMAP, client,
|
XRT_COLORMAP, client,
|
||||||
DixReadAccess);
|
DixReadAccess);
|
||||||
|
@ -210,7 +210,7 @@ PanoramiXChangeWindowAttributes(ClientPtr client)
|
||||||
if ((Mask) stuff->valueMask & CWColormap) {
|
if ((Mask) stuff->valueMask & CWColormap) {
|
||||||
cmap_offset = Ones((Mask) stuff->valueMask & (CWColormap - 1));
|
cmap_offset = Ones((Mask) stuff->valueMask & (CWColormap - 1));
|
||||||
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
||||||
if ((tmp != CopyFromParent) && (tmp != None)) {
|
if (tmp != CopyFromParent) {
|
||||||
result = dixLookupResourceByType((void **) &cmap, tmp,
|
result = dixLookupResourceByType((void **) &cmap, tmp,
|
||||||
XRT_COLORMAP, client,
|
XRT_COLORMAP, client,
|
||||||
DixReadAccess);
|
DixReadAccess);
|
||||||
|
|
|
@ -1143,7 +1143,7 @@ ProcScreenSaverSetAttributes(ClientPtr client)
|
||||||
if ((Mask) stuff->mask & CWColormap) {
|
if ((Mask) stuff->mask & CWColormap) {
|
||||||
cmap_offset = Ones((Mask) stuff->mask & (CWColormap - 1));
|
cmap_offset = Ones((Mask) stuff->mask & (CWColormap - 1));
|
||||||
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
tmp = *((CARD32 *) &stuff[1] + cmap_offset);
|
||||||
if ((tmp != CopyFromParent) && (tmp != None)) {
|
if (tmp != CopyFromParent) {
|
||||||
status = dixLookupResourceByType((void **) &cmap, tmp,
|
status = dixLookupResourceByType((void **) &cmap, tmp,
|
||||||
XRT_COLORMAP, client,
|
XRT_COLORMAP, client,
|
||||||
DixReadAccess);
|
DixReadAccess);
|
||||||
|
|
|
@ -1682,8 +1682,7 @@ ProcSetModifierMapping(ClientPtr client)
|
||||||
stuff->numKeyPerModifier);
|
stuff->numKeyPerModifier);
|
||||||
if (rc == MappingFailed || rc == -1)
|
if (rc == MappingFailed || rc == -1)
|
||||||
return BadValue;
|
return BadValue;
|
||||||
if (rc != Success && rc != MappingSuccess && rc != MappingFailed &&
|
if (rc != MappingSuccess && rc != MappingFailed && rc != MappingBusy)
|
||||||
rc != MappingBusy)
|
|
||||||
return rc;
|
return rc;
|
||||||
|
|
||||||
rep.success = rc;
|
rep.success = rc;
|
||||||
|
|
|
@ -264,7 +264,7 @@ configureDeviceSection(int screennum)
|
||||||
ptr->dev_busid = DevToConfig[screennum].GDev.busID;
|
ptr->dev_busid = DevToConfig[screennum].GDev.busID;
|
||||||
ptr->dev_driver = DevToConfig[screennum].GDev.driver;
|
ptr->dev_driver = DevToConfig[screennum].GDev.driver;
|
||||||
ptr->dev_ramdac = DevToConfig[screennum].GDev.ramdac;
|
ptr->dev_ramdac = DevToConfig[screennum].GDev.ramdac;
|
||||||
for (i = 0; (i < MAXDACSPEEDS) && (i < CONF_MAXDACSPEEDS); i++)
|
for (i = 0; i < MAXDACSPEEDS; i++)
|
||||||
ptr->dev_dacSpeeds[i] = DevToConfig[screennum].GDev.dacSpeeds[i];
|
ptr->dev_dacSpeeds[i] = DevToConfig[screennum].GDev.dacSpeeds[i];
|
||||||
ptr->dev_videoram = DevToConfig[screennum].GDev.videoRam;
|
ptr->dev_videoram = DevToConfig[screennum].GDev.videoRam;
|
||||||
ptr->dev_bios_base = DevToConfig[screennum].GDev.BiosBase;
|
ptr->dev_bios_base = DevToConfig[screennum].GDev.BiosBase;
|
||||||
|
|
|
@ -505,7 +505,7 @@ XkbHandleBell(BOOL force,
|
||||||
if ((!interest) || (force))
|
if ((!interest) || (force))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ((class == 0) || (class == KbdFeedbackClass)) {
|
if (class == KbdFeedbackClass) {
|
||||||
KeybdCtrl *pKeyCtrl = (KeybdCtrl *) pCtrl;
|
KeybdCtrl *pKeyCtrl = (KeybdCtrl *) pCtrl;
|
||||||
|
|
||||||
id = pKeyCtrl->id;
|
id = pKeyCtrl->id;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user