1
0
mirror of git://projects.qi-hardware.com/eda-tools.git synced 2024-12-22 18:21:44 +02:00

eeshow/gfx/pdftoc.c (line): don't be fooled by "/Type /Pages"

We really ought to test properly for end-of-word, not rely on prefixes.
This commit is contained in:
Werner Almesberger 2016-08-22 23:20:58 -03:00
parent cdb68f70a2
commit 44e17ff5ab

View File

@ -153,7 +153,8 @@ static void line(struct pdftoc *ctx, const char *s)
ctx->state = idle;
break;
}
if (strbegins(s, "<< /Type /Page")) {
if (strbegins(s, "<< /Type /Page") &&
!strbegins(s, "<< /Type /Pages")) {
ctx->curr_obj->is_page = 1;
break;
}