summaryrefslogtreecommitdiff
path: root/src/fclist.c
diff options
context:
space:
mode:
authorAkira TAGOH <akira@tagoh.org>2017-11-15 16:10:49 +0900
committerAkira TAGOH <akira@tagoh.org>2017-11-20 17:37:22 +0530
commit8f88b1c47cb7918aa65ed415f64e04464b1653c9 (patch)
tree2942722d8d96903a2bfc3dabb0a0c7fcd81b9801 /src/fclist.c
parent68ff99c4142e25989409f465e392b1bb3042494d (diff)
downloadfontconfig-8f88b1c47cb7918aa65ed415f64e04464b1653c9.tar.gz
abstract hash table functions
Diffstat (limited to 'src/fclist.c')
-rw-r--r--src/fclist.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/fclist.c b/src/fclist.c
index 835cc32..c78f55b 100644
--- a/src/fclist.c
+++ b/src/fclist.c
@@ -458,14 +458,16 @@ FcListAppend (FcListHashTable *table,
if (FcStat (FcValueString (&v->value), &statb) < 0)
{
FcChar8 *dir = FcStrDirname (FcValueString (&v->value));
- const FcChar8 *alias;
+ FcChar8 *alias;
+ FcConfig *config = FcConfigGetCurrent (); /* FIXME: this may need to be exported as API? */
- if ((alias = FcDirCacheFindAliasPath (dir)))
+ if (FcHashTableFind (config->alias_table, dir, (void **) &alias))
{
FcChar8 *base = FcStrBasename (FcValueString (&v->value));
FcChar8 *s = FcStrBuildFilename (alias, base, NULL);
FcValue vv;
+ FcStrFree (alias);
FcStrFree (base);
vv.type = FcTypeString;
vv.u.s = s;