Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.bugs.dist > #1278444
| From | Vincent Lefevre <vincent@vinc17.net> |
|---|---|
| Newsgroups | linux.debian.bugs.dist |
| Subject | Bug#1125474: libxm4: missing call to FcInit() when using Fontconfig |
| Date | 2026-01-15 11:00 +0100 |
| Message-ID | <MdsiZ-aHcS-5@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <Md8tX-au9P-1@gated-at.bofh.it> <Md8WZ-auBN-1@gated-at.bofh.it> <MdlUd-aDci-3@gated-at.bofh.it> <Md80W-au0j-13@gated-at.bofh.it> <MdlUd-aDci-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 2026-01-15 03:58:52 +0100, Vincent Lefevre wrote:
> I've added an abort() after the warning in Fontconfig, and I confirm
> that this is obtained via Motif. I've attached the backtrace.
>
> This happens via the ValidateAndLoadFont call:
>
> [...]
> #6 0x00007f172b316b89 in FcObjectFromName (name=name@entry=0x7f172b051b24 "encoding") at ./src/fcname.c:110
> No locals.
> #7 0x00007f172b319888 in IA__FcPatternAddString (p=0x55bb07356dc0, object=object@entry=0x7f172b051b24 "encoding", s=0x55bb0731f41
> 0 "iso10646-1") at ./src/fcpat.c:825
> No locals.
> #8 0x00007f172afa4b23 in ValidateAndLoadFont (rend=rend@entry=0x55bb07356d50, display=<optimized out>, display@entry=0x55bb07308550) at ./lib/Xm/XmRenderT.c:2107
> [...]
>
> and this function is defined in "lib/Xm/XmRenderT.c", and if
> I understand corretly, this is "case XmFONT_IS_XFT:".
The code in ValidateAndLoadFont() is the following:
[...]
_XmRendPattern(rend) = FcPatternCreate();
if (_XmRendFontName(rend))
FcPatternAddString(_XmRendPattern(rend), FC_FAMILY,
(XftChar8 *)_XmRendFontName(rend));
if (_XmRendFontFoundry(rend))
FcPatternAddString(_XmRendPattern(rend), FC_FOUNDRY,
(XftChar8 *)_XmRendFontFoundry(rend));
if (_XmRendFontEncoding(rend))
FcPatternAddString(_XmRendPattern(rend), XFT_ENCODING,
(XftChar8 *)_XmRendFontEncoding(rend));
if (_XmRendFontStyle(rend))
FcPatternAddString(_XmRendPattern(rend), FC_STYLE,
(XftChar8 *)_XmRendFontStyle(rend));
if (_XmRendFontSize(rend))
FcPatternAddInteger(_XmRendPattern(rend), FC_SIZE,
_XmRendFontSize(rend));
if (_XmRendPixelSize(rend))
FcPatternAddInteger(_XmRendPattern(rend), FC_PIXEL_SIZE,
_XmRendPixelSize(rend));
if (_XmRendFontSlant(rend))
FcPatternAddInteger(_XmRendPattern(rend), FC_SLANT,
_XmRendFontSlant(rend));
if (_XmRendFontWeight(rend))
FcPatternAddInteger(_XmRendPattern(rend), FC_WEIGHT,
_XmRendFontWeight(rend));
if (_XmRendFontSpacing(rend))
FcPatternAddInteger(_XmRendPattern(rend), FC_SPACING,
_XmRendFontSpacing(rend));
p = XftFontMatch(display, 0, _XmRendPattern(rend), &res);
[...]
It is the FcPatternAddString() call with XFT_ENCODING that triggers
the warning on my machine.
Note that XftFontMatch() will internally call XftInit(), which will
call FcInit(), but this occurs after the above FcPatternAddString()
call.
--
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Pascaline project (LIP, ENS-Lyon)
Back to linux.debian.bugs.dist | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Vincent Lefevre <vincent@vinc17.net> - 2026-01-14 13:20 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Adam Sampson <ats@offog.org> - 2026-01-14 13:50 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Vincent Lefevre <vincent@vinc17.net> - 2026-01-14 14:20 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Vincent Lefevre <vincent@vinc17.net> - 2026-01-14 14:20 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Vincent Lefevre <vincent@vinc17.net> - 2026-01-15 04:10 +0100
Bug#1125474: libxm4: missing call to FcInit() when using Fontconfig Vincent Lefevre <vincent@vinc17.net> - 2026-01-15 11:00 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Graham Inggs <ginggs@debian.org> - 2026-01-15 11:20 +0100
Bug#1125474: xpdf: Fontconfig warning: using without calling FcInit() Vincent Lefevre <vincent@vinc17.net> - 2026-01-15 11:50 +0100
csiph-web