Bug 574500 - BadMatch from XCreateWindow (different color depths)
BadMatch from XCreateWindow (different color depths)
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: desktop-effects (Show other bugs)
12
i686 Linux
low Severity medium
: ---
: ---
Assigned To: Owen Taylor
Fedora Extras Quality Assurance
abrt_hash:24fc7c778c10fc51d2e444793d5...
:
: 541985 550983 583311 583870 588208 588607 589460 590943 592715 593582 596596 597530 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-03-17 12:58 EDT by chuck elliot
Modified: 2010-07-07 13:48 EDT (History)
16 users (show)

See Also:
Fixed In Version: desktop-effects-0.8.7-2.fc13
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-07-07 13:48:30 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
File: backtrace (14.88 KB, text/plain)
2010-03-17 12:58 EDT, chuck elliot
no flags Details

  None (edit)
Description chuck elliot 2010-03-17 12:58:42 EDT
abrt 1.0.8 detected a crash.

architecture: i686
Attached file: backtrace
cmdline: desktop-effects
component: desktop-effects
executable: /usr/bin/desktop-effects
kernel: 2.6.32.9-70.fc12.i686
package: desktop-effects-0.8.4-2.fc12
rating: 4
reason: Process /usr/bin/desktop-effects was killed by signal 6 (SIGABRT)
release: Fedora release 12 (Constantine)

How to reproduce
-----
1. start it.
2.
3.
Comment 1 chuck elliot 2010-03-17 12:58:44 EDT
Created attachment 400829 [details]
File: backtrace
Comment 2 odeys87 2010-03-26 17:53:48 EDT

How to reproduce
-----
1.Power on Fedora12
2.Login to default non root account
3.Tried to open System-> Desktop Effects and it crashed without opening


Comment
-----
Could not open desktop effects, for some reason it is not opening at all.I am running Fedora12 on a virtual machine VMWare.

odeys87@gmail.com
Comment 3 Karel Klíč 2010-05-25 04:36:36 EDT
*** Bug 583870 has been marked as a duplicate of this bug. ***
Comment 4 Karel Klíč 2010-05-25 04:36:40 EDT
*** Bug 588208 has been marked as a duplicate of this bug. ***
Comment 5 Karel Klíč 2010-05-25 04:36:44 EDT
*** Bug 588607 has been marked as a duplicate of this bug. ***
Comment 6 Karel Klíč 2010-05-25 04:36:48 EDT
*** Bug 593582 has been marked as a duplicate of this bug. ***
Comment 7 Owen Taylor 2010-06-22 21:32:43 EDT
Error event:

xerror = {type = 0, display = 0x9169600, resourceid = 231, serial = 
    129, error_code = 8 '\b', request_code = 1 '\001', minor_code = 
    0 '\000'}

request code  1 is CreateWindow.
Comment 8 Owen Taylor 2010-06-22 21:51:38 EDT
*** Bug 590943 has been marked as a duplicate of this bug. ***
Comment 9 Owen Taylor 2010-06-22 21:54:06 EDT
*** Bug 596596 has been marked as a duplicate of this bug. ***
Comment 10 Owen Taylor 2010-06-22 22:31:22 EDT
*** Bug 583311 has been marked as a duplicate of this bug. ***
Comment 11 Owen Taylor 2010-06-22 22:31:38 EDT
*** Bug 589460 has been marked as a duplicate of this bug. ***
Comment 12 Owen Taylor 2010-06-22 22:32:06 EDT
*** Bug 592715 has been marked as a duplicate of this bug. ***
Comment 13 Owen Taylor 2010-06-22 22:32:33 EDT
*** Bug 597530 has been marked as a duplicate of this bug. ***
Comment 14 Owen Taylor 2010-06-22 22:49:07 EDT
There are at least several references to this being triggered by a 16bpp color dpth - in particular this was tracked down by Stuart Gathman in bug 583311; and in bug 597530 Andres Rios says "Cambiar la resolucion de pantalla de millones de colores a miles de colores" as a reproduction step.

The explanation, I think, of this bug can be seen in the X server code:


    if (((vmask & (CWBorderPixmap | CWBorderPixel)) == 0) &&
        (class != InputOnly) &&
        (depth != pParent->drawable.depth))
    {
        *error = BadMatch;
        return NullWindow;
    }

So if you don't provide a BorderPixmap or a BorderPixel (meaning that the border color is inherited from the parent), then you have to match the color depth of the parent. We can see a difference between the desktop-effects code:

  cwa.colormap = XCreateColormap(xdisplay, RootWindow (xdisplay, xscreen),
                                 visual->visual, AllocNone);
  window = XCreateWindow(xdisplay,
                         RootWindow (xdisplay, xscreen),
                         0, 0, 1, 1, 0,
                         visual->depth, InputOutput, visual->visual,
                         CWColormap,
                         &cwa);

And the glxinfo code:

   attr.background_pixel = 0;
   attr.border_pixel = 0;
   attr.colormap = XCreateColormap(dpy, root, visinfo->visual, AllocNone);
   attr.event_mask = StructureNotifyMask | ExposureMask;
   mask = CWBackPixel | CWBorderPixel | CWColormap | CWEventMask;
   win = XCreateWindow(dpy, root, 0, 0, width, height,
                       0, visinfo->depth, InputOutput,
                       visinfo->visual, mask, &attr);

Looking at the X server code, I can't see the reason for setting the BackPixel and the EventMask, though I think it's probably good to set the BackPixel just to be safe.
Comment 15 Owen Taylor 2010-06-22 22:50:42 EDT
*** Bug 541985 has been marked as a duplicate of this bug. ***
Comment 16 Owen Taylor 2010-06-22 22:52:16 EDT
*** Bug 550983 has been marked as a duplicate of this bug. ***
Comment 17 Fedora Update System 2010-06-23 13:22:51 EDT
desktop-effects-0.8.7-2.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/desktop-effects-0.8.7-2.fc13
Comment 18 Fedora Update System 2010-06-24 12:35:15 EDT
desktop-effects-0.8.7-2.fc13 has been pushed to the Fedora 13 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update desktop-effects'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/desktop-effects-0.8.7-2.fc13
Comment 19 James Laska 2010-06-30 10:18:16 EDT
Karel: Are you able to confirm this problem is fixed using the update posted in comment#18?  Please feel free to add feedback either here in bugzilla, or at http://admin.fedoraproject.org/updates/desktop-effects-0.8.7-2.fc13

Thanks!
Comment 20 chuck elliot 2010-06-30 16:16:23 EDT
Seems to be fixed in desktop-effects-0.8.7-2.fc13.x86_64

However, there is no third option 'GNOME3 preview' in the dialogue
as described in rpm -qi



Description :
desktop-effects provides a preference dialog to allow switching the GNOME
desktop between three different window managers: Metacity (the standard
GNOME 2 window manager), Compiz (offering 3D acceleration and special
effects), and GNOME Shell, which offers a preview of the GNOME 3 user
experience.

thanks & best wishes,
CE
Comment 21 Owen Taylor 2010-06-30 16:43:53 EDT
(In reply to comment #20)
> Seems to be fixed in desktop-effects-0.8.7-2.fc13.x86_64
> 
> However, there is no third option 'GNOME3 preview' in the dialogue
> as described in rpm -qi
> 
> Description :
> desktop-effects provides a preference dialog to allow switching the GNOME
> desktop between three different window managers: Metacity (the standard
> GNOME 2 window manager), Compiz (offering 3D acceleration and special
> effects), and GNOME Shell, which offers a preview of the GNOME 3 user
> experience.

You need to install the gnome-shell package in order to get this third option.
Comment 22 Fedora Update System 2010-07-07 13:48:19 EDT
desktop-effects-0.8.7-2.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.