public inbox for gcc-prs@sourceware.org help / color / mirror / Atom feed
From: adamh@densi.com To: gcc-gnats@gcc.gnu.org Subject: c/9699: rdesktop CVS compiles but exits with "ERROR: Less than 8 bpp not currently supported." Date: Fri, 14 Feb 2003 00:56:00 -0000 [thread overview] Message-ID: <20030214005352.4427.qmail@sources.redhat.com> (raw) >Number: 9699 >Category: c >Synopsis: rdesktop CVS compiles but exits with "ERROR: Less than 8 bpp not currently supported." >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Fri Feb 14 00:56:00 UTC 2003 >Closed-Date: >Last-Modified: >Originator: adamh@densi.com >Release: gcc-3_3-branch >Organization: >Environment: Linux 2.4.20, gcc-3.3 compiled from CVS today (2-13-03) glibc-2.3.1, XFree86 Version 3.2.1 Athlon XP 1600+, 256MB RAM >Description: So it looks like an rdesktop bug. So I went in to debug. I added a couple of lines of the source code to print out various warnings, compiled again, and it can connect to the server. I removed the warnings, recompiled, and it exits with the error, "ERROR: Less than 8 bpp not currently supported." I barely know C, so I apologize for not being able to think up a little example snippet of code. But I hope I've given enough information in the 'how-to-repeat' -- I for one can reproduce this behavior 100% of the time. I'll bet this is some kind of one-in-a-million thing, but here's the relevant snippet of code (in xwin.c, around line 525). pfm = XListPixmapFormats(display, &i); if (pfm != NULL) { /* Use maximum bpp for this depth - this is generally desirable, e.g. 24 bits->32 bits. */ while (i--) { if ((pfm[i].depth == depth) && (pfm[i].bits_per_pixel > bpp)) { bpp = pfm[i].bits_per_pixel; } } XFree(pfm); } if (bpp < 8) { error("Less than 8 bpp not currently supported.\n"); XCloseDisplay(display); return False; } >How-To-Repeat: $ export CVSROOT=:pserver:anonymous@cvs.rdesktop.sourceforge.net:/cvsroot/rdesktop $ cvs co rdesktop $ cd rdesktop $ ./configure $ make $ su -c 'make install' $ rdesktop www.example.com The program will exit with "ERROR: Less than 8 bpp not currently supported." Apply the following patch (to CVS checkout of 2-13-03): ------------------------------------------------------- diff -u -3 -p -r1.97 xwin.c --- xwin.c 10 Feb 2003 13:02:57 -0000 1.97 +++ xwin.c 14 Feb 2003 00:47:03 -0000 @@ -527,8 +527,10 @@ ui_init(void) { /* Use maximum bpp for this depth - this is generally desirable, e.g. 24 bits->32 bits. */ + warning("Real depth: %d, bpp: %d\n", depth, bpp); while (i--) { + warning("depth %d, bpp %d\n", pfm[i].depth, pfm[i].bits_per_pixel); if ((pfm[i].depth == depth) && (pfm[i].bits_per_pixel > bpp)) { bpp = pfm[i].bits_per_pixel; ------------------------------------------------------- $ make $ su -c 'make install' $ rdesktop www.example.com This time rdesktop will time out looking up www.example.com, which is what it should do. >Fix: I haven't a clue. This is my first bug report and I have a feeling it's a lousy one. I apologize in advance, and I'm aware that it's probably not a compiler bug, but I just can't see what else it could be when adding two harmless lines of code changes the program's behavior. >Release-Note: >Audit-Trail: >Unformatted:
next reply other threads:[~2003-02-14 0:56 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2003-02-14 0:56 adamh [this message] 2003-02-15 0:01 bangerth 2003-04-01 21:55 bangerth
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20030214005352.4427.qmail@sources.redhat.com \ --to=adamh@densi.com \ --cc=gcc-gnats@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).