summaryrefslogtreecommitdiff
path: root/Build/source/texk/kpathsea/kpsewhich.c
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2011-07-20 07:00:05 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2011-07-20 07:00:05 +0000
commit89755f7344de571c4b1b7c68e90de39363a4d1ff (patch)
treed735587f7030f0536272048df7a4b53cefc133a4 /Build/source/texk/kpathsea/kpsewhich.c
parent713aef9b071ca2b5dd68d014e99897f0e5e2036c (diff)
libs/t1lib + texk/ps2pkm: bug fix and update
git-svn-id: svn://tug.org/texlive/trunk@23187 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/kpathsea/kpsewhich.c')
-rw-r--r--Build/source/texk/kpathsea/kpsewhich.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/Build/source/texk/kpathsea/kpsewhich.c b/Build/source/texk/kpathsea/kpsewhich.c
index 7746bd7058d..7c453bc8eb0 100644
--- a/Build/source/texk/kpathsea/kpsewhich.c
+++ b/Build/source/texk/kpathsea/kpsewhich.c
@@ -129,7 +129,7 @@ static unsigned
find_dpi (string s)
{
unsigned dpi_number = 0;
- string extension = find_suffix (s);
+ const_string extension = find_suffix (s);
if (extension != NULL)
sscanf (extension, "%u", &dpi_number);
@@ -342,12 +342,15 @@ lookup (kpathsea kpse, string name)
case kpse_any_glyph_format:
{
kpse_glyph_file_type glyph_ret;
+ string temp = remove_suffix (name);
/* Try to extract the resolution from the name. */
unsigned local_dpi = find_dpi (name);
if (!local_dpi)
local_dpi = dpi;
- ret = kpathsea_find_glyph (kpse, remove_suffix (name),
+ ret = kpathsea_find_glyph (kpse, temp,
local_dpi, fmt, &glyph_ret);
+ if (temp != name)
+ free (temp);
}
break;