Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!munnari.oz.au!bunyip.cc.uq.oz.au!lance!ptcburp!fbm From: fbm@ptcburp.ptcbu.oz.au (Farrell McKay) Newsgroups: comp.windows.x Subject: Re: Quirky XtDestroyApplicationContext......??????? Message-ID: <1991May31.003453.27788@ptcburp.ptcbu.oz.au> Date: 31 May 91 00:34:53 GMT References: <1991May27.233521.8996@ptcburp.ptcbu.oz.au> <9105301635.AA24558@lyre.MIT.EDU> Organization: Pyramid Technology Corporation Lines: 54 swick@athena.mit.EDU (Ralph Swick) writes: > If you don't have R4 patched to fix #18 then some cases of StringToPixel > conversion ..... Since I first posted this article, I've been kicking myself for not detailing my X environment. Sorry. I am using X11R4 patch level 18. The only resources of relevance to the program (stored in the resource property on the server) were:- *borderColor: white *background: black It turns out that removing these resources makes the problem go away. It also turns out that the problem can be demonstrated without creating or realizing any widgets! Here is a simpler version of the original program which exhibits the same behaviour:- -m------- Farrell McKay, fbm@ptcburp.oz.au ---mmm----- Pyramid Technology Aust., ...!munnari!ptcburp.oz!fbm -----mmmmm--- Research Park, Bond University, +61 75 950256 -------mmmmmmm- Gold Coast, Qld 4229, AUSTRALIA +61 75 522475 FAX ---------------------------------- cut cut ------------------------------------- #include XtAppContext app; Widget top; /* * This program creates an application context, destroys it, and then exits. * To compile this program simply type:- * cc it.c -o it -lXt -lX11 * * Running this program generates the following message from within * XtCloseDisplay within XtDestroyApplication:- * * X Error of failed request: BadAccess (attempt to access private resource denied) * Major opcode of failed request: 88 (X_FreeColors) * Minor opcode of failed request: 0 * Resource id in failed request: 0x4077ffff * Serial number of failed request: 7 * Current serial number in output stream: 10 * */ main(argc, argv) int argc; char *argv[]; { top = XtAppInitialize(&app, "It", NULL, 0, &argc, argv, NULL, NULL, 0); XtDestroyApplicationContext(app); exit(0); }