diff --git a/src/fccache.c b/src/fccache.c index 8124e05..8581ae6 100644 --- a/src/fccache.c +++ b/src/fccache.c @@ -172,6 +172,7 @@ FcDirCacheBasenameMD5 (FcConfig *config, const FcChar8 *dir, FcChar8 cache_base[ key = (FcChar8 *) malloc (dl + sl + 1); memcpy (key, dir, dl); memcpy (key + dl, salt, sl + 1); + key[dl + sl] = 0; if (!orig_dir) orig_dir = dir; dir = key;