Re: Weird Font Bug?

Chisato Yamauchi <[email protected]>
Newsgroups gmane.comp.xfree86.fonts
Message-ID <[email protected]>
From: Fred Richards <[email protected]>
Subject: [Fonts] Weird Font Bug?
Date: Mon, 01 Mar 2004 22:26:29 -0500

> xterm.  But I noticed a problem.  Whenever I start an Xnest (from within 
> an already running X session) with the command Xnest :1 -ac &, then as 
> root run windomaker with wmaker -display :1 & ... I have a dock icon 
> that did with with 4.3.0, that basically loaded an xterm with a 10x20 
> font, but instead, I get this error:
> 
> root@tor:~# xterm -fn 10x20 -display :1
> X Error of failed request:  BadAlloc (insufficient resources for operation)
>   Major opcode of failed request:  45 (X_OpenFont)
>   Serial number of failed request:  49
>   Current serial number in output stream:  50

  I also got the error using Xnest.  It seems that 
doOpenFont() function of dixfonts.c returns AllocError
(line 327):

    if (!pfont->fpe)
        pfont->fpe = fpe;
    pfont->refcnt++;
    if (pfont->refcnt == 1) {
        UseFPE(pfont->fpe);
        for (i = 0; i < screenInfo.numScreens; i++) {
            pScr = screenInfo.screens[i];
            if (pScr->RealizeFont)
            {
                if (!(*pScr->RealizeFont) (pScr, pfont))
                {
                    CloseFont (pfont, (Font) 0);
                    err = AllocError;
                    goto bail;
                }
            }
        }
    }

  But I don't know the detail of this code...

------------------------------------------------------------
    Chisato Yamauchi
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.