From c46a92a2b93e3baa85cc9e130af1613142f9f524 Mon Sep 17 00:00:00 2001 From: Khaled Hosny Date: Sun, 28 Feb 2010 18:16:57 +0200 Subject: Correlate checksums to filenames This way when the file is moved around, its filename in the database will be updated, as suggested by Elie. --- luaotfload-fonts.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'luaotfload-fonts.lua') diff --git a/luaotfload-fonts.lua b/luaotfload-fonts.lua index 61d91e3..aeba0f1 100644 --- a/luaotfload-fonts.lua +++ b/luaotfload-fonts.lua @@ -46,7 +46,7 @@ luaotfload.fonts.directory = kpse.expand_var("$TEXMFVAR") .. luaotfload.fonts.su -- the version of the database, to be checked by the lookup function of -- luaotfload -luaotfload.fonts.version = 2.003 +luaotfload.fonts.version = 2.004 -- Log facilities: -- - level 0 is quiet @@ -136,11 +136,11 @@ local function load_font(filename, names, texmf) local checksums = names.checksums or { } if filename then local checksum = file.checksum(filename) - if checksums[checksum] then + if checksums[checksum] and checksums[checksum] == filename then log(3, "Font already indexed: %s", filename) return end - checksums[checksum] = 1 + checksums[checksum] = filename local info = fontloader.info(filename) if info then if type(info) == "table" and #info > 1 then -- cgit v1.2.3