summaryrefslogtreecommitdiff
path: root/backend/dvi/mdvi-lib
diff options
context:
space:
mode:
Diffstat (limited to 'backend/dvi/mdvi-lib')
-rw-r--r--backend/dvi/mdvi-lib/afmparse.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/backend/dvi/mdvi-lib/afmparse.c b/backend/dvi/mdvi-lib/afmparse.c
index 361e23d6..e1cd1156 100644
--- a/backend/dvi/mdvi-lib/afmparse.c
+++ b/backend/dvi/mdvi-lib/afmparse.c
@@ -190,7 +190,7 @@ static char *linetoken(FILE *stream)
while ((ch = fgetc(stream)) == ' ' || ch == '\t' );
idx = 0;
- while (ch != EOF && ch != lineterm)
+ while (ch != EOF && ch != lineterm && idx < MAX_NAME)
{
ident[idx++] = ch;
ch = fgetc(stream);