diff options
author | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2016-12-13 05:04:19 +0000 |
---|---|---|
committer | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2016-12-13 05:04:19 +0000 |
commit | c7c6cfc972293a3cdc8504cc038eaccded07a710 (patch) | |
tree | 1afd74e6c7b6a9f4c9f64564c4574b5233e44233 /Build/source | |
parent | a8c819d907340e1b10f2dc8baf524e05533e951d (diff) |
dvipsk: Fix a bug leading to wrong strlen (emstr). Thanks Norbert Klingen.
git-svn-id: svn://tug.org/texlive/trunk@42693 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source')
-rw-r--r-- | Build/source/texk/dvipsk/emspecial.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Build/source/texk/dvipsk/emspecial.c b/Build/source/texk/dvipsk/emspecial.c index e3d66431c08..38599bb27e3 100644 --- a/Build/source/texk/dvipsk/emspecial.c +++ b/Build/source/texk/dvipsk/emspecial.c @@ -160,7 +160,6 @@ char *emp; for (k = 0; k < 500; k++) emstr[k] = '\0'; } - hvpos(); for (emp = p+3; *emp && isspace((unsigned char)*emp); emp++); /* skip blanks */ if (strncmp(emp, "linewidth", 9) == 0) { @@ -292,7 +291,7 @@ char *emp; int i; for (emp = emp+5; *emp && isspace((unsigned char)*emp); emp++); /* skip blanks */ for (i=0; *emp && !isspace((unsigned char)*emp) && !(*emp==','); emp++) { - if (strlen(emstr) - 2 >= sizeof(emstr)) { + if (strlen (emstr) > 499) { fprintf(stderr, "em:graph: special too long, truncating\n"); break; } |