Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
*Description of problem:
In the default colormap, pixel 0 refers to black
color(0,0,0). However, pixel 0 refers to the other color
after my customer did the following operation.
1. Set the color depth to 8bit on RHEL4
2.Run XAllocNamedColor( dsp, cmap, "black", &color, &exact )
more than 32768 times, reference to black pixel shift to
other pixel number that is not 0.
3. Runs XAllocNamedColor with other color, pink for example,
RGB value of pixel 0 becomes the RGB value for pink. Thus
pixel 0 released black(0,0,0). This will show pink where
black should show in your screen.
*How reproducible:
Always.
*Steps to Reproduce:
The customer gave us the test program to reproduce this(See the attachment -
test_program.tar). Do the following.
1. Set the color depth to 8bit on RHEL4
2. Compile dumpcolor.c/allocblack.c/allocpink.c as follows.
gcc dumpcolor.c -lX11 -L /usr/X11R6/lib -o dumpcolor
gcc allocblack.c -lX11 -L /usr/X11R6/lib -o allocblack
gcc allocpink.c -lX11 -L /usr/X11R6/lib -o allocpink
3. Start X with mwm window manager -> xinit -e mwm
4. Run ./dumpcolor :0.0 0
5. Run ./allocblack :0.0 40000
-> At this stage, pixel 0 refers to the other pixel
6. Run ./allocpink :0.0
-> RGB of pink is placed in pixel 0
7. Run ./dumpcolor to see that pixel 0 now refers to RGB of
pink.
*Actual results:
pixel 0 refers to the other color.
*Expected results:
pixel 0 should refer to black color(0,0,0).
*Additional info:
This only occurs in color depth of 8bit.
We have posted this issue to xgl-devel and got the
following reply.
-------------------------------------------------------------
Subject:
Re: Pixel 0 shows RGB value thats are not black(0.0,0) with 8bit depth on RHEL4
From:
Adam Jackson <ajackson>
Date:
Tue, 26 Feb 2008 12:13:26 -0500
To:
xgl-devel
CC:
Kenji Suzuoki <ksuzuoki>
On Tue, 2008-02-26 at 17:51 +1000, Kenji Suzuoki wrote:
> > Hi there,
> >
> > A customer is asking if it is a X's bug that pixel 0 releases black
> > color(0,0,0) after certain condition.
> >
> > Setting color depth to 8bit on RHEL4, then run
> >
> > XAllocNamedColor( dsp, cmap, "black", &color, &exact ) ;
> >
> > more than 32768 times, reference to black pixel shift to other pixel
> > number that is not 0.
> >
> > After that if he runs XAllocNamedColor with other color, pink for
> > example, RGB value of pixel 0 becomes the RGB value for pink. Thus
> > pixel 0 released black(0,0,0).
> >
> > [ Questions ]
> > -----------------------------------------------------------------------
> > 1. Is this a bug ?
Yes. Yes, very much so.
Colormap slots have reference counts, so that when the client holding
that slot dies, it releases any slots it was holding on to. The
reference count happens to be a short int. D'oh. (Not even unsigned
short! Oh man.)
> > 2. Does RHEL4 support 8bit depth ?
Yes.
-------------------------------------------------------------
*Attachment
sysreport - RHEL4UP4.tar.bz2
test program - test_program.tar
result - our test result using the test program
Comment 8RHEL Program Management
2009-03-12 18:55:25 UTC
Since RHEL 4.8 External Beta has begun, and this bugzilla remains
unresolved, it has been rejected as it is not proposed as exception or
blocker.
Comment 11RHEL Program Management
2010-10-22 18:56:33 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.
The issue underlying this bug is still present in upstream Xorg. No further non-security updates are planned to X for RHEL4, so I'm retargeting this bug for RHEL7 development. Once and if fixed there it may be possible include this fix in a future RHEL6 backport. However, RHEL5's X server is ABI-frozen so this can not be fixed there.