Bug 179526 - segfault if ~/.fonts/fonts isnt there
Summary: segfault if ~/.fonts/fonts isnt there
Alias: None
Product: Fedora
Classification: Fedora
Component: fontconfig
Version: rawhide
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Carl Worth
QA Contact:
Depends On:
Blocks: FC5Blocker
TreeView+ depends on / blocked
Reported: 2006-02-01 03:32 UTC by Dave Jones
Modified: 2015-01-04 22:24 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2006-02-09 18:18:58 UTC
Type: ---

Attachments (Terms of Use)

Description Dave Jones 2006-02-01 03:32:55 UTC
I was testing fc-cache regeneration time, and did rm -rf .fonts/fonts
when I reran fc-cache, it segfaulted..

brk(0x1472000)                          = 0x1472000
stat("/home/davej/.fonts/fonts", 0x7fffffd35460) = -1 ENOENT (No such file or
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV (core dumped) +++

gdb says..
    at fccache.c:310
310             if (strncmp (d->name, dir, strlen(dir)) == 0)

#0  0x000000367c30ff6e in FcGlobalCacheReadDir (set=0x50ac20, dirs=Variable
"dirs" is not available.
    at fccache.c:310
#1  0x000000367c317179 in FcDirScanConfig (set=0x50ac20, dirs=0x5030e0,
    cache=0x507fd0, blanks=0x50a350, dir=0x507910 "/home/davej/.fonts/fonts",
    force=0, config=0x503010) at fcdir.c:142
#2  0x000000367c3128b7 in FcConfigBuildFonts (config=0x503010) at fccfg.c:304
#3  0x000000367c31a54d in FcInitLoadConfigAndFonts () at fcinit.c:85
#4  0x000000000040178d in main (argc=1, argv=0x7fffffd35778) at fc-cache.c:278
#5  0x0000003c3b91cde4 in __libc_start_main () from /lib64/libc.so.6
#6  0x00000000004010f9 in _start ()
#7  0x00007fffffd35768 in ?? ()
#8  0x0000000000000000 in ?? ()

Comment 1 Sammy 2006-02-02 20:46:28 UTC
I can confirm this as well. While the font cache problems seems to have
been resolved this one cast me an hour to discover today. In KDE it was
segfaulting things at the start which hang the entire login process.

Just building an empty .fonts directory and running mkfondir inside solves
the problem. Hopefully this is the last one!

Comment 2 Matthias Clasen 2006-02-08 07:09:28 UTC
mkfontdir has nothing to do with fontconfig caches. I'm not sure I understand
how exactly this problem occurs. Are you removing ~/.fonts _while_ fc-cache is
running , or do you remove it before running fc-cache ? And do you still see
this problem with todays fontconfig ?

Comment 3 Dave Jones 2006-02-09 18:18:58 UTC
seems to run to completion with latest rawhide.

Note You need to log in before you can comment on or make changes to this bug.